Exemple #1
0
 /// <summary>
 /// Delete a DigitalTwinsInstance.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group that contains the DigitalTwinsInstance.
 /// </param>
 /// <param name='resourceName'>
 /// The name of the DigitalTwinsInstance.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <DigitalTwinsDescription> DeleteAsync(this IDigitalTwinsOperations operations, string resourceGroupName, string resourceName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.DeleteWithHttpMessagesAsync(resourceGroupName, resourceName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #2
0
 /// <summary>
 /// Deletes a digital twin. All relationships referencing the digital twin must
 /// already be deleted.
 /// Status codes:
 /// 200 (OK): Success.
 /// 400 (Bad Request): The request is invalid.
 /// 404 (Not Found): There is no digital twin with the provided id.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// The id of the digital twin. The id is unique within the service and case
 /// sensitive.
 /// </param>
 /// <param name='ifMatch'>
 /// Only perform the operation if the entity's etag matches one of the etags
 /// provided or * is provided.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteAsync(this IDigitalTwinsOperations operations, string id, string ifMatch = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteWithHttpMessagesAsync(id, ifMatch, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }