IExceptionDetector.IsCancellation(Exception, CancellationToken) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns whether the provided exception represents a cancellation event for the current provider.
public bool IsCancellation (Exception exception, System.Threading.CancellationToken cancellationToken = default);
abstract member IsCancellation : Exception * System.Threading.CancellationToken -> bool
Public Function IsCancellation (exception As Exception, Optional cancellationToken As CancellationToken = Nothing) As Boolean
Parameters
- exception
- Exception
The exception to be checked for cancellation.
- cancellationToken
- CancellationToken
If exception
is insufficient for identifying a cancellation, this is the cancellation token passed to the
asynchronous operation; it can be checked instead as a fallback mechanism.
Returns
Applies to
Entity Framework
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for