/// <summary> /// Deletes a gateway from a resource group. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The resource group name uniquely identifies the resource group within the /// user subscriptionId. /// </param> /// <param name='gatewayName'> /// The gateway name (256 characters maximum). /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task DeleteAsync(this IGatewayOperations operations, string resourceGroupName, string gatewayName, CancellationToken cancellationToken = default(CancellationToken)) { await operations.DeleteWithHttpMessagesAsync(resourceGroupName, gatewayName, null, cancellationToken).ConfigureAwait(false); }
/// <summary> /// Deletes specific Gateway. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='serviceName'> /// The name of the API Management service. /// </param> /// <param name='gatewayId'> /// Gateway entity identifier. Must be unique in the current API Management /// service instance. Must not have value 'managed' /// </param> /// <param name='ifMatch'> /// ETag of the Entity. ETag should match the current entity state from the /// header response of the GET request or it should be * for unconditional /// update. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task DeleteAsync(this IGatewayOperations operations, string resourceGroupName, string serviceName, string gatewayId, string ifMatch, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.DeleteWithHttpMessagesAsync(resourceGroupName, serviceName, gatewayId, ifMatch, null, cancellationToken).ConfigureAwait(false)).Dispose(); }