public interface Subscription extends Cancelable
Subscription is the link to the actual running Task.
Due to the asynchronous nature of the Task execution a Subscription might not immediately become
active. isActive() provides an answer if the underlying Task is already running.
| Modifier and Type | Method and Description |
|---|---|
boolean |
await(Duration timeout)
|
boolean |
isActive() |
cancelboolean isActive()
boolean await(Duration timeout) throws InterruptedException
timeout - must not be null.true if the subscription was activated. false if the waiting time elapsed before task was
activated.InterruptedException - if the current thread is interrupted while waiting.Copyright © 2011–2020 Pivotal Software, Inc.. All rights reserved.