Class BlockingFirstObserver<T>
java.lang.Object
java.util.concurrent.CountDownLatch
io.reactivex.rxjava3.internal.observers.BlockingBaseObserver<T>
io.reactivex.rxjava3.internal.observers.BlockingFirstObserver<T>
- Type Parameters:
T- the value type
- All Implemented Interfaces:
Observer<T>, Disposable
Blocks until the upstream signals its first value or completes.
-
Field Summary
Fields inherited from class BlockingBaseObserver
cancelled, error, upstream, value -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class BlockingBaseObserver
blockingGet, dispose, isDisposed, onComplete, onSubscribe
-
Constructor Details
-
BlockingFirstObserver
public BlockingFirstObserver()
-
-
Method Details
-
onNext
Description copied from interface:ObserverProvides theObserverwith a new item to observe.The
Observablemay call this method 0 or more times.The
Observablewill not call this method again after it calls eitherObserver.onComplete()orObserver.onError(Throwable).- Parameters:
t- the item emitted by the Observable
-
onError
Description copied from interface:ObserverNotifies theObserverthat theObservablehas experienced an error condition.If the
Observablecalls this method, it will not thereafter callObserver.onNext(T)orObserver.onComplete().- Parameters:
t- the exception encountered by the Observable
-