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 io.reactivex.rxjava3.internal.observers.BlockingBaseObserver
cancelled, error, upstream, value
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class io.reactivex.rxjava3.internal.observers.BlockingBaseObserver
blockingGet, dispose, isDisposed, onComplete, onSubscribe
-
Constructor Details
-
BlockingFirstObserver
public BlockingFirstObserver()
-
-
Method Details
-
onNext
Description copied from interface:Observer
Provides theObserver
with a new item to observe.The
Observable
may call this method 0 or more times.The
Observable
will not call this method again after it calls eitherObserver.onComplete()
orObserver.onError(java.lang.Throwable)
.- Parameters:
t
- the item emitted by the Observable
-
onError
Description copied from interface:Observer
Notifies theObserver
that theObservable
has experienced an error condition.If the
Observable
calls this method, it will not thereafter callObserver.onNext(T)
orObserver.onComplete()
.- Parameters:
t
- the exception encountered by the Observable
-