IReliableDictionary<TKey,TValue>.ClearAsync 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.
Removes all keys and values from the Reliable Dictionary.
public System.Threading.Tasks.Task ClearAsync (TimeSpan timeout, System.Threading.CancellationToken cancellationToken);
abstract member ClearAsync : TimeSpan * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function ClearAsync (timeout As TimeSpan, cancellationToken As CancellationToken) As Task
Parameters
- timeout
- TimeSpan
The amount of time to wait for the operation to complete before throwing a TimeoutException. Primarily used to prevent deadlocks. The default is 4 seconds.
- cancellationToken
- CancellationToken
The token to monitor for cancellation requests. The default is None.
Returns
Task that represents the asynchronous clear operation.
Exceptions
timeout
is negative.
The operation failed to complete within the given timeout.
The operation was canceled.
The exception that is thrown when the IReliableDictionary<TKey,TValue> is not in Primary.
Applies to
Commenti e suggerimenti
https://aka.ms/ContentUserFeedback.
Presto disponibile: Nel corso del 2024 verranno gradualmente disattivati i problemi di GitHub come meccanismo di feedback per il contenuto e ciò verrà sostituito con un nuovo sistema di feedback. Per altre informazioni, vedereInvia e visualizza il feedback per