Equality Operator

Task Parallel System.Threading

Determines whether two CancellationToken instances are equal.

Namespace:  System.Threading
Assembly:  System.Threading (in System.Threading.dll)

Syntax

Visual Basic (Declaration)
Public Shared Operator = ( _
	left As CancellationToken, _
	right As CancellationToken _
) As Boolean
C#
public static bool operator ==(
	CancellationToken left,
	CancellationToken right
)

Parameters

left
Type: System.Threading..::.CancellationToken
The first instance.
right
Type: System.Threading..::.CancellationToken
The second instance.

Return Value

True if the instances are equal; otherwise, false.

Exceptions

ExceptionCondition
System..::.ObjectDisposedExceptionAn associated CancellationTokenSource has been disposed.

See Also