Adds a cancelable reference to this composite.
Cancels the unit of work represented by this reference.
Cancels the unit of work represented by this reference.
Guaranteed idempotency - calling it multiple times should have the same side-effect as calling it only a single time. Implementations of this method should also be thread-safe.
true if cancellation happened, or false if another execution happened previously or concurrently.
true in case this cancelable hasn't been canceled.
Removes a cancelable reference from this composite.
Adds a cancelable reference to this composite.
Adds a cancelable reference to this composite.
This is an alias for add()
.
Removes a cancelable reference from this composite.
Removes a cancelable reference from this composite.
This is an alias for remove()
.
Represents a composite of multiple cancelables. In case it is canceled, all contained cancelables will be canceled too, e.g...
Additionally, once canceled, on appending of new cancelable references, those references will automatically get canceled too:
Adding and removing references from this composite is thread-safe.