|
|
喝醉的小笼包 · BtHaha | BT蚂蚁磁力· 3 月前 · |
|
|
强悍的酸菜鱼 · 出行平台与出租车的融合难题:司机线上化之困与 ...· 4 月前 · |
|
|
乐观的卤蛋 · Pinyin Lyrics 八仙饭店 (8 ...· 5 月前 · |
|
|
腼腆的手链 · 地球日|“全球战塑”,塑料污染新难题如何应对 ...· 1 年前 · |
|
|
寂寞的警车 · 百度网盘pdf转图片 - 百度· 1 年前 · |
static
Completable
amb
(java.lang.Iterable<? extends
CompletableSource
> sources)
static
Completable
ambArray
(
CompletableSource
... sources)
Completable
ambWith
(
CompletableSource
other)
Completable
andThen
(
CompletableSource
next)
<T>
Maybe
<T>
andThen
(
MaybeSource
<T> next)
Maybe
which will subscribe to this Completable and once that is completed then
will subscribe to the
next
MaybeSource.
<T>
Observable
<T>
andThen
(
ObservableSource
<T> next)
next
ObservableSource.
<T>
Flowable
<T>
andThen
(org.reactivestreams.Publisher<T> next)
next
Flowable.
<T>
Single
<T>
andThen
(
SingleSource
<T> next)
next
SingleSource.
blockingAwait
()
boolean
blockingAwait
(long timeout,
java.util.concurrent.TimeUnit unit)
java.lang.Throwable
blockingGet
()
java.lang.Throwable
blockingGet
(long timeout,
java.util.concurrent.TimeUnit unit)
Completable
cache
()
static
Completable
complete
()
Completable
compose
(
CompletableTransformer
transformer)
static
Completable
concat
(java.lang.Iterable<? extends
CompletableSource
> sources)
static
Completable
concat
(org.reactivestreams.Publisher<? extends
CompletableSource
> sources)
static
Completable
concat
(org.reactivestreams.Publisher<? extends
CompletableSource
> sources,
int prefetch)
static
Completable
concatArray
(
CompletableSource
... sources)
Completable
concatWith
(
CompletableSource
other)
static
Completable
create
(
CompletableOnSubscribe
source)
static
Completable
defer
(java.util.concurrent.Callable<? extends
CompletableSource
> completableSupplier)
Completable
delay
(long delay,
java.util.concurrent.TimeUnit unit)
Completable
delay
(long delay,
java.util.concurrent.TimeUnit unit,
Scheduler
scheduler)
Completable
delay
(long delay,
java.util.concurrent.TimeUnit unit,
Scheduler
scheduler,
boolean delayError)
Completable
doAfterTerminate
(
Action
onAfterTerminate)
doAfterTerminate
does not operate by default on a particular
Scheduler
.
Completable
doFinally
(
Action
onFinally)
Completable
doOnComplete
(
Action
onComplete)
Completable
doOnDispose
(
Action
onDispose)
Completable
doOnError
(
Consumer
<? super java.lang.Throwable> onError)
Completable
doOnEvent
(
Consumer
<? super java.lang.Throwable> onEvent)
Completable
doOnSubscribe
(
Consumer
<? super
Disposable
> onSubscribe)
Completable
doOnTerminate
(
Action
onTerminate)
doOnTerminate
does not operate by default on a particular
Scheduler
.
static
Completable
error
(java.util.concurrent.Callable<? extends java.lang.Throwable> errorSupplier)
static
Completable
error
(java.lang.Throwable error)
static
Completable
fromAction
(
Action
run)
static
Completable
fromCallable
(java.util.concurrent.Callable<?> callable)
static
Completable
fromFuture
(java.util.concurrent.Future<?> future)
static <T>
Completable
fromObservable
(
ObservableSource
<T> observable)
static <T>
Completable
fromPublisher
(org.reactivestreams.Publisher<T> publisher)
static
Completable
fromRunnable
(java.lang.Runnable run)
static <T>
Completable
fromSingle
(
SingleSource
<T> single)
Completable
hide
()
Completable
lift
(
CompletableOperator
onLift)
static
Completable
merge
(java.lang.Iterable<? extends
CompletableSource
> sources)
static
Completable
merge
(org.reactivestreams.Publisher<? extends
CompletableSource
> sources)
static
Completable
merge
(org.reactivestreams.Publisher<? extends
CompletableSource
> sources,
int maxConcurrency)
static
Completable
mergeArray
(
CompletableSource
... sources)
static
Completable
mergeArrayDelayError
(
CompletableSource
... sources)
static
Completable
mergeDelayError
(java.lang.Iterable<? extends
CompletableSource
> sources)
static
Completable
mergeDelayError
(org.reactivestreams.Publisher<? extends
CompletableSource
> sources)
static
Completable
mergeDelayError
(org.reactivestreams.Publisher<? extends
CompletableSource
> sources,
int maxConcurrency)
Completable
mergeWith
(
CompletableSource
other)
static
Completable
never
()
Completable
observeOn
(
Scheduler
scheduler)
Completable
onErrorComplete
()
Completable
onErrorComplete
(
Predicate
<? super java.lang.Throwable> predicate)
Completable
onErrorResumeNext
(
Function
<? super java.lang.Throwable,? extends
CompletableSource
> errorMapper)
Completable
repeat
()
Completable
repeat
(long times)
Completable
repeatUntil
(
BooleanSupplier
stop)
Completable
repeatWhen
(
Function
<? super
Flowable
<java.lang.Object>,? extends org.reactivestreams.Publisher<java.lang.Object>> handler)
Completable
retry
()
Completable
retry
(
BiPredicate
<? super java.lang.Integer,? super java.lang.Throwable> predicate)
Completable
retry
(long times)
Completable
retry
(
Predicate
<? super java.lang.Throwable> predicate)
Completable
retryWhen
(
Function
<? super
Flowable
<java.lang.Throwable>,? extends org.reactivestreams.Publisher<java.lang.Object>> handler)
Completable
startWith
(
CompletableSource
other)
<T>
Observable
<T>
startWith
(
Observable
<T> other)
<T>
Flowable
<T>
startWith
(org.reactivestreams.Publisher<T> other)
Disposable
subscribe
()
Disposable
subscribe
(
Action
onComplete)
Disposable
subscribe
(
Action
onComplete,
Consumer
<? super java.lang.Throwable> onError)
subscribe
(
CompletableObserver
s)
protected abstract void
subscribeActual
(
CompletableObserver
s)
Completable
subscribeOn
(
Scheduler
scheduler)
<E extends
CompletableObserver
>
E
subscribeWith
(E observer)
TestObserver
<java.lang.Void>
test
()
TestObserver
<java.lang.Void>
test
(boolean cancelled)
Completable
timeout
(long timeout,
java.util.concurrent.TimeUnit unit)
Completable
timeout
(long timeout,
java.util.concurrent.TimeUnit unit,
CompletableSource
other)
Completable
timeout
(long timeout,
java.util.concurrent.TimeUnit unit,
Scheduler
scheduler)
Completable
timeout
(long timeout,
java.util.concurrent.TimeUnit unit,
Scheduler
scheduler,
CompletableSource
other)
static
Completable
timer
(long delay,
java.util.concurrent.TimeUnit unit)
static
Completable
timer
(long delay,
java.util.concurrent.TimeUnit unit,
Scheduler
scheduler)
to
(
Function
<? super
Completable
,U> converter)
<T>
Flowable
<T>
toFlowable
()
<T>
Maybe
<T>
toMaybe
()
Maybe
.
<T>
Observable
<T>
toObservable
()
<T>
Single
<T>
toSingle
(java.util.concurrent.Callable<? extends T> completionValueSupplier)
<T>
Single
<T>
toSingleDefault
(T completionValue)
static
Completable
unsafeCreate
(
CompletableSource
source)
Completable
unsubscribeOn
(
Scheduler
scheduler)
unsubscribeOn
calls dispose() of the upstream on the
Scheduler
you specify.
static <R>
Completable
using
(java.util.concurrent.Callable<R> resourceSupplier,
Function
<? super R,? extends
CompletableSource
> completableFunction,
Consumer
<? super R> disposer)
static <R>
Completable
using
(java.util.concurrent.Callable<R> resourceSupplier,
Function
<? super R,? extends
CompletableSource
> completableFunction,
Consumer
<? super R> disposer,
boolean eager)
static
Completable
wrap
(
CompletableSource
source)
@CheckReturnValue @SchedulerSupport(value="none") public static Completable ambArray(CompletableSource... sources)
ambArray
does not operate by default on a particular
Scheduler
.
sources
- the array of source Completables. A subscription to each source will
occur in the same order as in this array.
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable amb(java.lang.Iterable<? extends CompletableSource> sources)
amb
does not operate by default on a particular
Scheduler
.
sources
- the array of source Completables. A subscription to each source will
occur in the same order as in this Iterable.
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable complete()
complete
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="none") public static Completable concatArray(CompletableSource... sources)
concatArray
does not operate by default on a particular
Scheduler
.
sources
- the sources to concatenate
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable concat(java.lang.Iterable<? extends CompletableSource> sources)
concat
does not operate by default on a particular
Scheduler
.
sources
- the sources to concatenate
java.lang.NullPointerException
- if sources is null
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
concat
does not operate by default on a particular
Scheduler
.
sources
- the sources to concatenate
java.lang.NullPointerException
- if sources is null
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
concat
does not operate by default on a particular
Scheduler
.
sources
- the sources to concatenate
prefetch
- the number of sources to prefetch from the sources
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable create(CompletableOnSubscribe source)
create
does not operate by default on a particular
Scheduler
.
source
- the emitter that is called when a CompletableObserver subscribes to the returned
Completable
CompletableOnSubscribe
,
Cancellable
@CheckReturnValue @SchedulerSupport(value="none") public static Completable unsafeCreate(CompletableSource source)
unsafeCreate
does not operate by default on a particular
Scheduler
.
source
- the callback which will receive the CompletableObserver instances
when the Completable is subscribed to.
java.lang.NullPointerException
- if source is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable defer(java.util.concurrent.Callable<? extends CompletableSource> completableSupplier)
defer
does not operate by default on a particular
Scheduler
.
completableSupplier
- the supplier that returns the Completable that will be subscribed to.
@CheckReturnValue @SchedulerSupport(value="none") public static Completable error(java.util.concurrent.Callable<? extends java.lang.Throwable> errorSupplier)
error
does not operate by default on a particular
Scheduler
.
errorSupplier
- the error supplier, not null
java.lang.NullPointerException
- if errorSupplier is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable error(java.lang.Throwable error)
error
does not operate by default on a particular
Scheduler
.
error
- the Throwable instance to emit, not null
java.lang.NullPointerException
- if error is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable fromAction(Action run)
fromAction
does not operate by default on a particular
Scheduler
.
run
- the runnable to run for each subscriber
java.lang.NullPointerException
- if run is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable fromCallable(java.util.concurrent.Callable<?> callable)
fromCallable
does not operate by default on a particular
Scheduler
.
callable
- the callable instance to execute for each subscriber
@CheckReturnValue @SchedulerSupport(value="none") public static Completable fromFuture(java.util.concurrent.Future<?> future)
fromFuture
does not operate by default on a particular
Scheduler
.
future
- the future to react to
@CheckReturnValue @SchedulerSupport(value="none") public static Completable fromRunnable(java.lang.Runnable run)
fromRunnable
does not operate by default on a particular
Scheduler
.
run
- the runnable to run for each subscriber
java.lang.NullPointerException
- if run is null
@CheckReturnValue @SchedulerSupport(value="none") public static <T> Completable fromObservable(ObservableSource<T> observable)
fromObservable
does not operate by default on a particular
Scheduler
.
T
- the type of the Observable
observable
- the Observable instance to subscribe to, not null
java.lang.NullPointerException
- if flowable is null
@CheckReturnValue @BackpressureSupport(value=UNBOUNDED_IN) @SchedulerSupport(value="none") public static <T> Completable fromPublisher(org.reactivestreams.Publisher<T> publisher)
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
fromPublisher
does not operate by default on a particular
Scheduler
.
T
- the type of the publisher
publisher
- the Publisher instance to subscribe to, not null
java.lang.NullPointerException
- if publisher is null
@CheckReturnValue @SchedulerSupport(value="none") public static <T> Completable fromSingle(SingleSource<T> single)
fromSingle
does not operate by default on a particular
Scheduler
.
T
- the value type of the Single
single
- the Single instance to subscribe to, not null
java.lang.NullPointerException
- if single is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable mergeArray(CompletableSource... sources)
mergeArray
does not operate by default on a particular
Scheduler
.
sources
- the iterable sequence of sources.
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable merge(java.lang.Iterable<? extends CompletableSource> sources)
merge
does not operate by default on a particular
Scheduler
.
sources
- the iterable sequence of sources.
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") @BackpressureSupport(value=UNBOUNDED_IN) public static Completable merge(org.reactivestreams.Publisher<? extends CompletableSource> sources)
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
merge
does not operate by default on a particular
Scheduler
.
sources
- the iterable sequence of sources.
java.lang.NullPointerException
- if sources is null
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
merge
does not operate by default on a particular
Scheduler
.
sources
- the iterable sequence of sources.
maxConcurrency
- the maximum number of concurrent subscriptions
java.lang.NullPointerException
- if sources is null
java.lang.IllegalArgumentException
- if maxConcurrency is less than 1
@CheckReturnValue @SchedulerSupport(value="none") public static Completable mergeArrayDelayError(CompletableSource... sources)
mergeArrayDelayError
does not operate by default on a particular
Scheduler
.
sources
- the array of Completables
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") public static Completable mergeDelayError(java.lang.Iterable<? extends CompletableSource> sources)
mergeDelayError
does not operate by default on a particular
Scheduler
.
sources
- the sequence of Completables
java.lang.NullPointerException
- if sources is null
@CheckReturnValue @SchedulerSupport(value="none") @BackpressureSupport(value=UNBOUNDED_IN) public static Completable mergeDelayError(org.reactivestreams.Publisher<? extends CompletableSource> sources)
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
mergeDelayError
does not operate by default on a particular
Scheduler
.
sources
- the sequence of Completables
java.lang.NullPointerException
- if sources is null
Completable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
mergeDelayError
does not operate by default on a particular
Scheduler
.
sources
- the sequence of Completables
maxConcurrency
- the maximum number of concurrent subscriptions to Completables
java.lang.NullPointerException
- if sources is null
never
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="io.reactivex:computation") public static Completable timer(long delay, java.util.concurrent.TimeUnit unit)
timer
does operate by default on the
computation
Scheduler
.
delay
- the delay time
unit
- the delay unit
@CheckReturnValue @SchedulerSupport(value="custom") public static Completable timer(long delay, java.util.concurrent.TimeUnit unit, Scheduler scheduler)
timer
operates on the
Scheduler
you specify.
delay
- the delay time
unit
- the delay unit
scheduler
- the scheduler where to emit the complete event
@CheckReturnValue @SchedulerSupport(value="none") public static <R> Completable using(java.util.concurrent.Callable<R> resourceSupplier, Function<? super R,? extends CompletableSource> completableFunction, Consumer<? super R> disposer)
using
does not operate by default on a particular
Scheduler
.
R
- the resource type
resourceSupplier
- the supplier that returns a resource to be managed.
completableFunction
- the function that given a resource returns a Completable instance that will be subscribed to
disposer
- the consumer that disposes the resource created by the resource supplier
@CheckReturnValue @SchedulerSupport(value="none") public static <R> Completable using(java.util.concurrent.Callable<R> resourceSupplier, Function<? super R,? extends CompletableSource> completableFunction, Consumer<? super R> disposer, boolean eager)
using
does not operate by default on a particular
Scheduler
.
R
- the resource type
resourceSupplier
- the supplier that returns a resource to be managed
completableFunction
- the function that given a resource returns a non-null
Completable instance that will be subscribed to
disposer
- the consumer that disposes the resource created by the resource supplier
eager
- if true, the resource is disposed before the terminal event is emitted, if false, the
resource is disposed after the terminal event has been emitted
@CheckReturnValue @SchedulerSupport(value="none") public static Completable wrap(CompletableSource source)
wrap
does not operate by default on a particular
Scheduler
.
source
- the source to wrap
java.lang.NullPointerException
- if source is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable ambWith(CompletableSource other)
ambWith
does not operate by default on a particular
Scheduler
.
other
- the other Completable, not null. A subscription to this provided source will occur after subscribing
to the current source.
java.lang.NullPointerException
- if other is null
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Observable<T> andThen(ObservableSource<T> next)
next
ObservableSource. An error event from this Completable will be
propagated to the downstream subscriber and will result in skipping the subscription of the
Observable.
andThen
does not operate by default on a particular
Scheduler
.
T
- the value type of the next ObservableSource
next
- the Observable to subscribe after this Completable is completed, not null
java.lang.NullPointerException
- if next is null
next
Flowable. An error event from this Completable will be
propagated to the downstream subscriber and will result in skipping the subscription of the
Publisher.
Flowable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
andThen
does not operate by default on a particular
Scheduler
.
T
- the value type of the next Publisher
next
- the Publisher to subscribe after this Completable is completed, not null
java.lang.NullPointerException
- if next is null
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Single<T> andThen(SingleSource<T> next)
next
SingleSource. An error event from this Completable will be
propagated to the downstream subscriber and will result in skipping the subscription of the
Single.
andThen
does not operate by default on a particular
Scheduler
.
T
- the value type of the next SingleSource
next
- the Single to subscribe after this Completable is completed, not null
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Maybe<T> andThen(MaybeSource<T> next)
Maybe
which will subscribe to this Completable and once that is completed then
will subscribe to the
next
MaybeSource. An error event from this Completable will be
propagated to the downstream subscriber and will result in skipping the subscription of the
Maybe.
andThen
does not operate by default on a particular
Scheduler
.
T
- the value type of the next MaybeSource
next
- the Maybe to subscribe after this Completable is completed, not null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable andThen(CompletableSource next)
concatWith(CompletableSource)
.
andThen
does not operate by default on a particular
Scheduler
.
next
- the other Completable, not null
java.lang.NullPointerException
- if other is null
@SchedulerSupport(value="none") public final void blockingAwait()
blockingAwait
does not operate by default on a particular
Scheduler
.
java.lang.RuntimeException
- wrapping an InterruptedException if the current thread is interrupted
@CheckReturnValue @SchedulerSupport(value="none") public final boolean blockingAwait(long timeout, java.util.concurrent.TimeUnit unit)
blockingAwait
does not operate by default on a particular
Scheduler
.
timeout
- the timeout value
unit
- the timeout unit
java.lang.RuntimeException
- wrapping an InterruptedException if the current thread is interrupted
@CheckReturnValue @SchedulerSupport(value="none") public final java.lang.Throwable blockingGet()
blockingGet
does not operate by default on a particular
Scheduler
.
java.lang.RuntimeException
- that wraps an InterruptedException if the wait is interrupted
@CheckReturnValue @SchedulerSupport(value="none") public final java.lang.Throwable blockingGet(long timeout, java.util.concurrent.TimeUnit unit)
blockingGet
does not operate by default on a particular
Scheduler
.
timeout
- the timeout value
unit
- the time unit
java.lang.RuntimeException
- that wraps an InterruptedException if the wait is interrupted or
TimeoutException if the specified timeout elapsed before it
cache
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="none") public final Completable compose(CompletableTransformer transformer)
compose
does not operate by default on a particular
Scheduler
.
transformer
- the transformer function, not null
java.lang.NullPointerException
- if transformer is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable concatWith(CompletableSource other)
concatWith
does not operate by default on a particular
Scheduler
.
other
- the other Completable, not null
java.lang.NullPointerException
- if other is null
@CheckReturnValue @SchedulerSupport(value="io.reactivex:computation") public final Completable delay(long delay, java.util.concurrent.TimeUnit unit)
delay
does operate by default on the
computation
Scheduler
.
delay
- the delay time
unit
- the delay unit
java.lang.NullPointerException
- if unit is null
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable delay(long delay, java.util.concurrent.TimeUnit unit, Scheduler scheduler)
delay
operates on the
Scheduler
you specify.
delay
- the delay time
unit
- the delay unit
scheduler
- the scheduler to run the delayed completion on
java.lang.NullPointerException
- if unit or scheduler is null
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable delay(long delay, java.util.concurrent.TimeUnit unit, Scheduler scheduler, boolean delayError)
delay
operates on the
Scheduler
you specify.
delay
- the delay time
unit
- the delay unit
scheduler
- the scheduler to run the delayed completion on
delayError
- delay the error emission as well?
java.lang.NullPointerException
- if unit or scheduler is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doOnComplete(Action onComplete)
doOnComplete
does not operate by default on a particular
Scheduler
.
onComplete
- the callback to call when this emits an onComplete event
java.lang.NullPointerException
- if onComplete is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doOnDispose(Action onDispose)
doOnDispose
does not operate by default on a particular
Scheduler
.
onDispose
- the callback to call when the child subscriber disposes the subscription
java.lang.NullPointerException
- if onDispose is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doOnError(Consumer<? super java.lang.Throwable> onError)
doOnError
does not operate by default on a particular
Scheduler
.
onError
- the error callback
java.lang.NullPointerException
- if onError is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doOnEvent(Consumer<? super java.lang.Throwable> onEvent)
doOnEvent
does not operate by default on a particular
Scheduler
.
onEvent
- the event callback
java.lang.NullPointerException
- if onEvent is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doOnSubscribe(Consumer<? super Disposable> onSubscribe)
doOnSubscribe
does not operate by default on a particular
Scheduler
.
onSubscribe
- the callback called when a child subscriber subscribes
java.lang.NullPointerException
- if onSubscribe is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doOnTerminate(Action onTerminate)
doOnTerminate
does not operate by default on a particular
Scheduler
.
onTerminate
- the callback to call just before this Completable terminates
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doAfterTerminate(Action onAfterTerminate)
doAfterTerminate
does not operate by default on a particular
Scheduler
.
onAfterTerminate
- the callback to call after this Completable terminates
@CheckReturnValue @SchedulerSupport(value="none") public final Completable doFinally(Action onFinally)
In case of a race between a terminal event and a dispose call, the provided
onFinally
action
is executed once per subscription.
Note that the
onFinally
action is shared between subscriptions and as such
should be thread-safe.
doFinally
does not operate by default on a particular
Scheduler
.
onFinally
- the action called when this Completable terminates or gets cancelled
@CheckReturnValue @SchedulerSupport(value="none") public final Completable lift(CompletableOperator onLift)
lift
does not operate by default on a particular
Scheduler
.
onLift
- the lifting function that transforms the child subscriber with a parent subscriber.
java.lang.NullPointerException
- if onLift is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable mergeWith(CompletableSource other)
mergeWith
does not operate by default on a particular
Scheduler
.
other
- the other Completable instance
java.lang.NullPointerException
- if other is null
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable observeOn(Scheduler scheduler)
observeOn
operates on a
Scheduler
you specify.
scheduler
- the scheduler to emit terminal events on
java.lang.NullPointerException
- if scheduler is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable onErrorComplete()
onErrorComplete
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="none") public final Completable onErrorComplete(Predicate<? super java.lang.Throwable> predicate)
onErrorComplete
does not operate by default on a particular
Scheduler
.
predicate
- the predicate to call when an Throwable is emitted which should return true
if the Throwable should be swallowed and replaced with an onComplete.
@CheckReturnValue @SchedulerSupport(value="none") public final Completable onErrorResumeNext(Function<? super java.lang.Throwable,? extends CompletableSource> errorMapper)
onErrorResumeNext
does not operate by default on a particular
Scheduler
.
errorMapper
- the mapper function that takes the error and should return a Completable as
continuation.
repeat
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="none") public final Completable repeat(long times)
repeat
does not operate by default on a particular
Scheduler
.
times
- the number of times the resubscription should happen
java.lang.IllegalArgumentException
- if times is less than zero
@CheckReturnValue @SchedulerSupport(value="none") public final Completable repeatUntil(BooleanSupplier stop)
repeatUntil
does not operate by default on a particular
Scheduler
.
stop
- the supplier that should return true to stop resubscribing.
java.lang.NullPointerException
- if stop is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable repeatWhen(Function<? super Flowable<java.lang.Object>,? extends org.reactivestreams.Publisher<java.lang.Object>> handler)
repeatWhen
does not operate by default on a particular
Scheduler
.
handler
- the function that transforms the stream of values indicating the completion of
this Completable and returns a Publisher that emits items for repeating or completes to indicate the
repetition should stop
java.lang.NullPointerException
- if stop is null
retry
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="none") public final Completable retry(BiPredicate<? super java.lang.Integer,? super java.lang.Throwable> predicate)
retry
does not operate by default on a particular
Scheduler
.
predicate
- the predicate called when this emits an error with the repeat count and the latest exception
and should return true to retry.
@CheckReturnValue @SchedulerSupport(value="none") public final Completable retry(long times)
retry
does not operate by default on a particular
Scheduler
.
times
- the number of times the returned Completable should retry this Completable
java.lang.IllegalArgumentException
- if times is negative
@CheckReturnValue @SchedulerSupport(value="none") public final Completable retry(Predicate<? super java.lang.Throwable> predicate)
retry
does not operate by default on a particular
Scheduler
.
predicate
- the predicate that is called with the latest throwable and should return
true to indicate the returned Completable should resubscribe to this Completable.
java.lang.NullPointerException
- if predicate is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable retryWhen(Function<? super Flowable<java.lang.Throwable>,? extends org.reactivestreams.Publisher<java.lang.Object>> handler)
retryWhen
does not operate by default on a particular
Scheduler
.
handler
- the handler that receives a Flowable delivering Throwables and should return a Publisher that
emits items to indicate retries or emits terminal events to indicate termination.
java.lang.NullPointerException
- if handler is null
@CheckReturnValue @SchedulerSupport(value="none") public final Completable startWith(CompletableSource other)
startWith
does not operate by default on a particular
Scheduler
.
other
- the other completable to run first
java.lang.NullPointerException
- if other is null
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Observable<T> startWith(Observable<T> other)
startWith
does not operate by default on a particular
Scheduler
.
T
- the value type
other
- the other Observable to run first
java.lang.NullPointerException
- if other is null
Flowable
honors the backpressure of the downstream consumer
and expects the other
Publisher
to honor it as well.
startWith
does not operate by default on a particular
Scheduler
.
T
- the value type
other
- the other Publisher to run first
java.lang.NullPointerException
- if other is null
Allows preventing certain identity-based optimizations (fusion).
hide
does not operate by default on a particular
Scheduler
.
@SchedulerSupport(value="none") public final Disposable subscribe()
subscribe
does not operate by default on a particular
Scheduler
.
@SchedulerSupport(value="none") public final void subscribe(CompletableObserver s)
CompletableSource
subscribe
in interface
CompletableSource
s
- the CompletableObserver, not null
protected abstract void subscribeActual(CompletableObserver s)
s
- the CompletableObserver instance, never null
@CheckReturnValue @SchedulerSupport(value="none") public final <E extends CompletableObserver> E subscribeWith(E observer)
Usage example: Completable source = Completable.complete().delay(1, TimeUnit.SECONDS); CompositeDisposable composite = new CompositeDisposable(); class ResourceCompletableObserver implements CompletableObserver, Disposable { // ... composite.add(source.subscribeWith(new ResourceCompletableObserver()));
subscribeWith
does not operate by default on a particular
Scheduler
.
E
- the type of the CompletableObserver to use and return
observer
- the CompletableObserver (subclass) to use and return, not null
observer
java.lang.NullPointerException
- if
observer
is null
@CheckReturnValue @SchedulerSupport(value="none") public final Disposable subscribe(Action onComplete, Consumer<? super java.lang.Throwable> onError)
subscribe
does not operate by default on a particular
Scheduler
.
onComplete
- the runnable that is called if the Completable completes normally
onError
- the consumer that is called if this Completable emits an error
java.lang.NullPointerException
- if either callback is null
@CheckReturnValue @SchedulerSupport(value="none") public final Disposable subscribe(Action onComplete)
OnErrorNotImplementedException
and routed to the RxJavaPlugins.onError handler.
subscribe
does not operate by default on a particular
Scheduler
.
onComplete
- the runnable called when this Completable completes normally
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable subscribeOn(Scheduler scheduler)
subscribeOn
operates on a
Scheduler
you specify.
scheduler
- the Scheduler to subscribe on
java.lang.NullPointerException
- if scheduler is null
@CheckReturnValue @SchedulerSupport(value="io.reactivex:computation") public final Completable timeout(long timeout, java.util.concurrent.TimeUnit unit)
timeout
signals the TimeoutException on the
computation
Scheduler
.
timeout
- the timeout value
unit
- the timeout unit
java.lang.NullPointerException
- if unit is null
@CheckReturnValue @SchedulerSupport(value="io.reactivex:computation") public final Completable timeout(long timeout, java.util.concurrent.TimeUnit unit, CompletableSource other)
timeout
subscribes to the other CompletableSource on
the
computation
Scheduler
.
timeout
- the timeout value
unit
- the timeout unit
other
- the other Completable instance to switch to in case of a timeout
java.lang.NullPointerException
- if unit or other is null
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable timeout(long timeout, java.util.concurrent.TimeUnit unit, Scheduler scheduler)
timeout
signals the TimeoutException on the
Scheduler
you specify.
timeout
- the timeout value
unit
- the timeout unit
scheduler
- the scheduler to use to wait for completion
java.lang.NullPointerException
- if unit or scheduler is null
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable timeout(long timeout, java.util.concurrent.TimeUnit unit, Scheduler scheduler, CompletableSource other)
timeout
subscribes to the other CompletableSource on
the
Scheduler
you specify.
timeout
- the timeout value
unit
- the timeout unit
scheduler
- the scheduler to use to wait for completion
other
- the other Completable instance to switch to in case of a timeout
java.lang.NullPointerException
- if unit, scheduler or other is null
@CheckReturnValue @SchedulerSupport(value="none") public final <U> U to(Function<? super Completable,U> converter)
to
does not operate by default on a particular
Scheduler
.
U
- the output type
converter
- the function called with this which should return some other value.
java.lang.NullPointerException
- if converter is null
Flowable
honors the backpressure of the downstream consumer.
toFlowable
does not operate by default on a particular
Scheduler
.
T
- the value type
toMaybe
does not operate by default on a particular
Scheduler
.
T
- the value type
Maybe
that emits a single item T or an error.
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Observable<T> toObservable()
toObservable
does not operate by default on a particular
Scheduler
.
T
- the value type
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Single<T> toSingle(java.util.concurrent.Callable<? extends T> completionValueSupplier)
toSingle
does not operate by default on a particular
Scheduler
.
T
- the value type
completionValueSupplier
- the value supplier called when this Completable completes normally
java.lang.NullPointerException
- if completionValueSupplier is null
@CheckReturnValue @SchedulerSupport(value="none") public final <T> Single<T> toSingleDefault(T completionValue)
toSingleDefault
does not operate by default on a particular
Scheduler
.
T
- the value type
completionValue
- the value to emit when this Completable completes normally
java.lang.NullPointerException
- if completionValue is null
@CheckReturnValue @SchedulerSupport(value="custom") public final Completable unsubscribeOn(Scheduler scheduler)
unsubscribeOn
calls dispose() of the upstream on the
Scheduler
you specify.
scheduler
- the target scheduler where to execute the cancellation
java.lang.NullPointerException
- if scheduler is null
@CheckReturnValue @SchedulerSupport(value="none") public final TestObserver<java.lang.Void> test()
test
does not operate by default on a particular
Scheduler
.
@CheckReturnValue @SchedulerSupport(value="none") public final TestObserver<java.lang.Void> test(boolean cancelled)
cancelled
- if true, the TestObserver will be cancelled before subscribing to this
Completable.
test
does not operate by default on a particular
Scheduler
.
|
|
喝醉的小笼包 · BtHaha | BT蚂蚁磁力 3 月前 |
|
|
乐观的卤蛋 · Pinyin Lyrics 八仙饭店 (8 Immortals Restaurant) - 吞吐 (Tun Tu ) (Puff) 歌词 - Pinyin Lyrics 歌词 English Tra 5 月前 |
|
|
寂寞的警车 · 百度网盘pdf转图片 - 百度 1 年前 |