A Processor that allows a single Subscriber at a time,
and can subscribe to only one Publisher at a time.
The implementation acts as a Subscriber to upstream input,
and acts as a Publisher for the downstream output.
Subclasses implement the transformation of the input elements into the
output elements by overriding onNext(Object).
| Modifier and Type | Field and Description |
|---|---|
| private long | |
| private Subscription |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | cancel()
Overrides org. Implements org. Publisher to stop sending data and clean up resources.
|
| protected Subscriber | |
| private void | |
| private void | |
| protected void | |
| public void | |
| public void | onError(Throwable
the throwable signaled throwable)Implements org. |
| protected void | onFailure(Subscriber<? super O> subscriber, Throwable failure)
Overrides org. |
| protected void | onRequest(Subscriber<? super O> subscriber, long n)
Implements abstract org. |
| public void | onSubscribe(Subscription
the subscription)Subscription that allows requesting data via Subscription#request(long)Implements org. Publisher#subscribe(Subscriber).
|
| public String | toString()
Overrides org. |
| private Subscription | |
| protected void | |
| protected void | |
| private void |
| demand | back to summary |
|---|---|
| private long demand | |
| upStream | back to summary |
|---|---|
| private Subscription upStream | |
| AbstractSingleProcessor | back to summary |
|---|---|
| public AbstractSingleProcessor() | |
| cancel | back to summary |
|---|---|
| public void cancel() Overrides org. Implements org. Doc from org. Request the Data may still be sent to meet previously signalled demand after calling cancel.
| |
| downStream | back to summary |
|---|---|
| protected Subscriber | |
| downStreamOnComplete | back to summary |
|---|---|
| private void downStreamOnComplete() | |
| downStreamOnError | back to summary |
|---|---|
| private void downStreamOnError(Throwable throwable) | |
| downStreamOnNext | back to summary |
|---|---|
| protected void downStreamOnNext(O item) | |
| onComplete | back to summary |
|---|---|
| public void onComplete() Implements org. Doc from org. Successful terminal state.
No further events will be sent even if
| |
| onError | back to summary |
|---|---|
| public void onError(Throwable throwable) Implements org. Doc from org. Failed terminal state.
No further events will be sent even if | |
| onFailure | back to summary |
|---|---|
| protected void onFailure(Subscriber<? super O> subscriber, Throwable failure) Overrides org.
| |
| onRequest | back to summary |
|---|---|
| protected void onRequest(Subscriber<? super O> subscriber, long n) Implements abstract org.
| |
| onSubscribe | back to summary |
|---|---|
| public void onSubscribe(Subscription subscription) Implements org. Doc from org. Invoked after calling
No data will start flowing until
It is the responsibility of this
The
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides org. Doc from java. Returns a string representation of the object. | |
| upStream | back to summary |
|---|---|
| private Subscription upStream() | |
| upStreamCancel | back to summary |
|---|---|
| protected void upStreamCancel() | |
| upStreamRequest | back to summary |
|---|---|
| protected void upStreamRequest(long n) | |
| upStreamRequest | back to summary |
|---|---|
| private void upStreamRequest(Subscription upStream, long demand) | |