T- Type of value emitted by this
public final class ScalarValueSubscription<T> extends java.lang.Object implements PublisherSource.Subscription
PublisherSource.Subscriptionthat only emits a single value.
|Constructor and Description|
|Modifier and Type||Method and Description|
Sends a hint to the producer of the associated asynchronous execution that the consumer related to this
public ScalarValueSubscription(@Nullable T value, PublisherSource.Subscriber<? super T> subscriber)
value- to be emitted by this
subscriber- to emit the value to when requested.
public void request(long n)
nmore items from the associated
PublisherSourcefor the associated
See Reactive Streams specifications for the rules about how and when this method will be invoked.
n- Number of items to request.
public void cancel()
Cancellableis not interested in the outcome of the execution.