-
- Enclosing class:
- Flow
public static interface Flow.Subscription
-
-
方法详细信息
-
request
void request(long n)
将给定数量的n项目添加到此订阅的当前未实现的需求中。 如果n小于或等于零,则订户将收到onError信号与IllegalArgumentException参数。 否则,订阅者最多可以收到n额外的onNext调用(如果终止则更少)。- 参数
-
n- 需求增量 价值Long.MAX_VALUE可能被视为有效无限
-
cancel
void cancel()
Causes the Subscriber to (eventually) stop receiving messages. Implementation is best-effort -- additional messages may be received after invoking this method. A cancelled subscription need not ever receive anonCompleteoronErrorsignal.
-
-