CancellationTokenSourceExtensionsCancelAfter Method |
Namespace: Rackspace.Threading
Exception | Condition |
---|---|
ArgumentNullException | If cts is . |
ObjectDisposedException | If cts has been disposed. |
ArgumentOutOfRangeException | If the TotalMilliseconds property of delay is less than -1 or greater than MaxValue. |
In all versions of .NET, requesting cancellation of a CancellationTokenSource will not prevent the instance from becoming eligible for garbage collection prior to the timer expiring. In .NET 4 and newer, any associated Timer instance will become eligible for garbage collection at the same time as the associated CancellationTokenSource.