Class DisposableAutoReleaseMultiObserver<T>
- java.lang.Object
-
- java.util.concurrent.atomic.AtomicReference<Disposable>
-
- io.reactivex.rxjava3.internal.observers.AbstractDisposableAutoRelease
-
- io.reactivex.rxjava3.internal.observers.DisposableAutoReleaseMultiObserver<T>
-
- Type Parameters:
T- the element type consumed
- All Implemented Interfaces:
CompletableObserver,MaybeObserver<T>,SingleObserver<T>,Disposable,LambdaConsumerIntrospection,java.io.Serializable
public final class DisposableAutoReleaseMultiObserver<T> extends AbstractDisposableAutoRelease implements SingleObserver<T>, MaybeObserver<T>, CompletableObserver
Wraps lambda callbacks and when the upstream terminates or this (Single | Maybe | Completable) observer gets disposed, removes itself from aCompositeDisposable.History: 0.18.0 @ RxJavaExtensions
- Since:
- 3.1.0
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description (package private) Consumer<? super T>onSuccessprivate static longserialVersionUID-
Fields inherited from class io.reactivex.rxjava3.internal.observers.AbstractDisposableAutoRelease
composite, onComplete, onError
-
-
Constructor Summary
Constructors Constructor Description DisposableAutoReleaseMultiObserver(DisposableContainer composite, Consumer<? super T> onSuccess, Consumer<? super java.lang.Throwable> onError, Action onComplete)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidonSuccess(T t)Notifies theSingleObserverwith a single item and that theSinglehas finished sending push-based notifications.-
Methods inherited from class io.reactivex.rxjava3.internal.observers.AbstractDisposableAutoRelease
dispose, hasCustomOnError, isDisposed, onComplete, onError, onSubscribe, removeSelf
-
Methods inherited from class java.util.concurrent.atomic.AtomicReference
accumulateAndGet, compareAndExchange, compareAndExchangeAcquire, compareAndExchangeRelease, compareAndSet, get, getAcquire, getAndAccumulate, getAndSet, getAndUpdate, getOpaque, getPlain, lazySet, set, setOpaque, setPlain, setRelease, toString, updateAndGet, weakCompareAndSet, weakCompareAndSetAcquire, weakCompareAndSetPlain, weakCompareAndSetRelease, weakCompareAndSetVolatile
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface io.reactivex.rxjava3.core.CompletableObserver
onComplete, onError, onSubscribe
-
Methods inherited from interface io.reactivex.rxjava3.core.MaybeObserver
onComplete, onError, onSubscribe
-
Methods inherited from interface io.reactivex.rxjava3.core.SingleObserver
onError, onSubscribe
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
DisposableAutoReleaseMultiObserver
public DisposableAutoReleaseMultiObserver(DisposableContainer composite, Consumer<? super T> onSuccess, Consumer<? super java.lang.Throwable> onError, Action onComplete)
-
-
Method Detail
-
onSuccess
public void onSuccess(T t)
Description copied from interface:SingleObserverNotifies theSingleObserverwith a single item and that theSinglehas finished sending push-based notifications.The
Singlewill not call this method if it callsSingleObserver.onError(java.lang.Throwable).- Specified by:
onSuccessin interfaceMaybeObserver<T>- Specified by:
onSuccessin interfaceSingleObserver<T>- Parameters:
t- the item emitted by theSingle
-
-