MCPcopy Index your code
hub / github.com/ReactiveX/RxJava / compose

Method compose

src/main/java/io/reactivex/rxjava3/core/Single.java:2632–2638  ·  view source on GitHub ↗

Transform a Single by applying a particular SingleTransformer function to it. This method operates on the Single itself whereas {@link #l

(@NonNull SingleTransformer<? super T, ? extends R> transformer)

Source from the content-addressed store, hash-verified

2630 * @see <a href="https://github.com/ReactiveX/RxJava/wiki/Implementing-Your-Own-Operators">RxJava wiki: Implementing Your Own Operators</a>
2631 */
2632 @SuppressWarnings("unchecked")
2633 @CheckReturnValue
2634 @SchedulerSupport(SchedulerSupport.NONE)
2635 @NonNull
2636 public final <@NonNull R> Single<R> compose(@NonNull SingleTransformer<? super T, ? extends R> transformer) {
2637 return wrap(((SingleTransformer<T, R>) Objects.requireNonNull(transformer, "transformer is null")).apply(this));
2638 }
2639
2640 /**
2641 * Stores the success value or exception from the current {@code Single} and replays it to late {@link SingleObserver}s.

Callers

nothing calls this directly

Calls 2

wrapMethod · 0.95
applyMethod · 0.65

Tested by

no test coverage detected