MCPcopy Index your code
hub / github.com/ReactiveX/RxJavaComputationExpressions / ifThen

Method ifThen

src/main/java/rx/Statement.java:157–159  ·  view source on GitHub ↗

Return an Observable that emits the emissions from a specified Observable if a condition evaluates to true, otherwise return an empty Observable. @param the result value typ

(Func0<Boolean> condition, Observable<? extends R> then)

Source from the content-addressed store, hash-verified

155 * Observable otherwise
156 */
157 public static <R> Observable<R> ifThen(Func0<Boolean> condition, Observable<? extends R> then) {
158 return ifThen(condition, then, Observable.<R> empty());
159 }
160
161 /**
162 * Return an Observable that emits the emissions from a specified Observable

Callers 5

testIfThenMethod · 0.95
testIfThenElseMethod · 0.95

Calls

no outgoing calls

Tested by 5

testIfThenMethod · 0.76
testIfThenElseMethod · 0.76