| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final int | CANCELLED
Cancel has been called. |
| pack-priv static final int | NO_REQUEST
No request has been issued yet. |
| pack-priv static final int | REQUESTED
Request has been called. |
| private static final long | |
| pack-priv final Subscriber | subscriber
The actual subscriber. |
| pack-priv final T | value
The single value to emit, set to null.
|
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | cancel()
Implements org. Publisher to stop sending data and clean up resources.
|
| public void | clear()
Implements io. |
| public boolean | Returns: true if this Subscription was cancelledReturns true if this Subscription was cancelled. |
| public boolean | isEmpty()
Implements io. |
| public boolean | offer(T
the value to enqueue, not null e)Implements io. |
| public boolean | offer(T
the first value to enqueue, not null v1, T the second value to enqueue, not null v2)Implements io. |
| public T | poll()
Implements io. |
| public void | request(long
the strictly positive number of elements to requests to the upstream n)PublisherImplements org. Publisher until demand is signaled via this method.
|
| public int | requestFusion(int mode)
Implements io. |
| CANCELLED | back to summary |
|---|---|
| pack-priv static final int CANCELLED Cancel has been called. | |
| NO_REQUEST | back to summary |
|---|---|
| pack-priv static final int NO_REQUEST No request has been issued yet. | |
| REQUESTED | back to summary |
|---|---|
| pack-priv static final int REQUESTED Request has been called. | |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides java. | |
| subscriber | back to summary |
|---|---|
| pack-priv final Subscriber<? super T> subscriber The actual subscriber. | |
| value | back to summary |
|---|---|
| pack-priv final T value Hides java. The single value to emit, set to null. | |
| ScalarSubscription | back to summary |
|---|---|
| public ScalarSubscription(Subscriber<? super T> subscriber, T value) | |
| cancel | back to summary |
|---|---|
| public void cancel() Implements org. Doc from org. Request the Data may still be sent to meet previously signalled demand after calling cancel.
| |
| clear | back to summary |
|---|---|
| public void clear() Implements io. Doc from io. Removes all enqueued items from this queue.
| |
| isCancelled | back to summary |
|---|---|
| public boolean isCancelled() Returns true if this Subscription was cancelled.
| |
| isEmpty | back to summary |
|---|---|
| public boolean isEmpty() Implements io. Doc from io. Returns true if the queue is empty.
Note however that due to potential fused functions in
| |
| offer | back to summary |
|---|---|
| public boolean offer(T e) Implements io. Doc from io. Atomically enqueue a single value.
| |
| offer | back to summary |
|---|---|
| public boolean offer(T v1, T v2) Implements io. Doc from io. Atomically enqueue two values.
| |
| poll | back to summary |
|---|---|
| public T poll() Implements io. Doc from io. Tries to dequeue a value (non-null) or returns null if the queue is empty.
If the producer uses | |
| request | back to summary |
|---|---|
| public void request(long n) Implements org. Doc from org. No events will be sent by a
It can be called however often and whenever needed—but if the outstanding cumulative demand ever becomes Long.MAX_VALUE or more,
it may be treated by the
Whatever has been requested can be sent by the
A | |
| requestFusion | back to summary |
|---|---|
| public int requestFusion(int mode) Implements io. Doc from io. Request a fusion mode from the upstream.
This should be called before
Calling this method multiple times or after
| |