Package io.github.resilience4j
Class AbstractObserver<T>
java.lang.Object
io.github.resilience4j.AbstractDisposable
io.github.resilience4j.AbstractObserver<T>
- All Implemented Interfaces:
io.reactivex.disposables.Disposable
,io.reactivex.Observer<T>
public abstract class AbstractObserver<T> extends AbstractDisposable implements io.reactivex.Observer<T>
-
Field Summary
Fields Modifier and Type Field Description protected java.util.concurrent.atomic.AtomicBoolean
eventWasEmitted
-
Constructor Summary
Constructors Constructor Description AbstractObserver(io.reactivex.Observer<? super T> downstreamObserver)
-
Method Summary
Modifier and Type Method Description protected abstract void
hookOnComplete()
protected abstract void
hookOnError(java.lang.Throwable e)
protected void
hookOnSubscribe()
void
onComplete()
void
onError(java.lang.Throwable e)
void
onNext(T item)
Methods inherited from class io.github.resilience4j.AbstractDisposable
dispose, hookOnCancel, isDisposed, onSubscribe, toString
-
Field Details
-
eventWasEmitted
protected final java.util.concurrent.atomic.AtomicBoolean eventWasEmitted
-
-
Constructor Details
-
Method Details
-
hookOnSubscribe
protected void hookOnSubscribe()- Specified by:
hookOnSubscribe
in classAbstractDisposable
-
onNext
- Specified by:
onNext
in interfaceio.reactivex.Observer<T>
-
onError
public void onError(java.lang.Throwable e)- Specified by:
onError
in interfaceio.reactivex.Observer<T>
-
hookOnError
protected abstract void hookOnError(java.lang.Throwable e) -
onComplete
public void onComplete()- Specified by:
onComplete
in interfaceio.reactivex.Observer<T>
-
hookOnComplete
protected abstract void hookOnComplete()
-