ServiceClient.PurgeMessageQueueAsync(String, 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.
Removes all cloud-to-device messages from a device's queue. This call is made over HTTP.
public virtual System.Threading.Tasks.Task<Microsoft.Azure.Devices.PurgeMessageQueueResult> PurgeMessageQueueAsync (string deviceId, System.Threading.CancellationToken cancellationToken = default);
abstract member PurgeMessageQueueAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.PurgeMessageQueueResult>
override this.PurgeMessageQueueAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.PurgeMessageQueueResult>
Public Overridable Function PurgeMessageQueueAsync (deviceId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of PurgeMessageQueueResult)
Parameters
- deviceId
- String
The device identifier for the target device.
- cancellationToken
- CancellationToken
A cancellation token to cancel the operation.
Returns
Applies to
Samarbeta med oss på GitHub
Källan för det här innehållet finns på GitHub, där du även kan skapa och granska ärenden och pull-begäranden. Se vår deltagarguide för mer information.
Azure SDK for .NET