InterruptionTokenSource

InterruptionTokenSource class

Represents the source of InterruptionToken.

InterruptionTokenSource

NameDescription
InterruptionTokenSource()Creates a new InterruptionTokenSource.

Returns: InterruptionTokenSource


getToken

NameDescription
getToken ()Returns new token binded to this InterruptionTokenSource.

Returns: InterruptionToken


interrupt

NameDescription
interrupt ()Initialize request for interruption.

Returns: void


isInterruptionRequested

NameDescription
isInterruptionRequested ()Returns true if interruption requested, false otherwise.

Returns: boolean