IDistributedCache.RemoveAsync 方法
定义
重载
| RemoveAsync(String) | |
| RemoveAsync(String, CancellationToken) |
删除具有给定键的值。Removes the value with the given key. |
RemoveAsync(String)
RemoveAsync(String, CancellationToken)
删除具有给定键的值。Removes the value with the given key.
public System.Threading.Tasks.Task RemoveAsync (string key, System.Threading.CancellationToken token = default);
abstract member RemoveAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function RemoveAsync (key As String, Optional token As CancellationToken = Nothing) As Task
参数
- key
- String
用于标识所请求的值的字符串。A string identifying the requested value.
- token
- CancellationToken
可选。Optional. CancellationToken,用于传播应取消操作的通知。The CancellationToken used to propagate notifications that the operation should be canceled.
返回
表示异步操作的 Task。The Task that represents the asynchronous operation.