Skip to content

Commit e858315

Browse files
committed
Added nonstatic Observable.finally0
1 parent 64a02a6 commit e858315

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

rxjava-core/src/main/java/rx/Observable.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2426,6 +2426,17 @@ public Observable<T> filter(Func1<T, Boolean> predicate) {
24262426
return filter(this, predicate);
24272427
}
24282428

2429+
/**
2430+
* Registers an action to be called when this observable calls
2431+
* <code>onComplete</code> or <code>onError</code>.
2432+
* @param action an action to be called when this observable completes or errors.
2433+
* @return an Observable that emits the same objects as this observable, then calls the action.
2434+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh212133(v=vs.103).aspx">MSDN: Observable.Finally Method</a>
2435+
*/
2436+
public Observable<T> finally0(Action0 action) {
2437+
return _create(OperationFinally.finally0(this, action));
2438+
}
2439+
24292440
/**
24302441
* Filters an Observable by discarding any of its emissions that do not meet some test.
24312442
* <p>

0 commit comments

Comments
 (0)