Struct CancellationTokenMultiplexer.ScopeWithTimeout
Represents a scope that controls the lifetime of the multiplexed cancellation token and allows to specify the timeout.
Inherited Members
Namespace: DotNext.Threading
Assembly: DotNext.Threading.dll
Syntax
public readonly struct CancellationTokenMultiplexer.ScopeWithTimeout : IMultiplexedCancellationTokenSource, IDisposable, IAsyncDisposable
Properties
| Edit this page View SourceCancellationOrigin
Gets the cancellation origin.
Declaration
public CancellationToken CancellationOrigin { get; }
Property Value
| Type | Description |
|---|---|
| CancellationToken |
IsTimedOut
Gets a value indicating that the multiplexed token is cancelled by the timeout.
Declaration
public bool IsTimedOut { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Timeout
Sets the optional timeout.
Declaration
public TimeSpan Timeout { set; }
Property Value
| Type | Description |
|---|---|
| TimeSpan |
See Also
| Edit this page View SourceToken
Gets the multiplexed token.
Declaration
public CancellationToken Token { get; }
Property Value
| Type | Description |
|---|---|
| CancellationToken |
Methods
| Edit this page View SourceDispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
public void Dispose()
DisposeAsync()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources asynchronously.
Declaration
public ValueTask DisposeAsync()
Returns
| Type | Description |
|---|---|
| ValueTask | A task that represents the asynchronous dispose operation. |