/// <summary> /// Patches specific backend. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.ApiManagement.IBackendOperations. /// </param> /// <param name='resourceGroupName'> /// Required. The name of the resource group. /// </param> /// <param name='serviceName'> /// Required. The name of the Api Management service. /// </param> /// <param name='backendid'> /// Required. Identifier of the backend. /// </param> /// <param name='parameters'> /// Required. Update parameters. /// </param> /// <param name='etag'> /// Required. ETag. /// </param> /// <returns> /// A standard service response including an HTTP status code and /// request ID. /// </returns> public static Task <AzureOperationResponse> UpdateAsync(this IBackendOperations operations, string resourceGroupName, string serviceName, string backendid, BackendUpdateParameters parameters, string etag) { return(operations.UpdateAsync(resourceGroupName, serviceName, backendid, parameters, etag, CancellationToken.None)); }
/// <summary> /// Patches specific backend. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.ApiManagement.IBackendOperations. /// </param> /// <param name='resourceGroupName'> /// Required. The name of the resource group. /// </param> /// <param name='serviceName'> /// Required. The name of the Api Management service. /// </param> /// <param name='backendid'> /// Required. Identifier of the backend. /// </param> /// <param name='parameters'> /// Required. Update parameters. /// </param> /// <param name='etag'> /// Required. ETag. /// </param> /// <returns> /// A standard service response including an HTTP status code and /// request ID. /// </returns> public static AzureOperationResponse Update(this IBackendOperations operations, string resourceGroupName, string serviceName, string backendid, BackendUpdateParameters parameters, string etag) { return(Task.Factory.StartNew((object s) => { return ((IBackendOperations)s).UpdateAsync(resourceGroupName, serviceName, backendid, parameters, etag); } , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult()); }
/// <summary> /// Updates an existing backend. /// </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='backendId'> /// Identifier of the Backend entity. Must be unique in the current API /// Management service instance. /// </param> /// <param name='parameters'> /// Update parameters. /// </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 <BackendContract> UpdateAsync(this IBackendOperations operations, string resourceGroupName, string serviceName, string backendId, BackendUpdateParameters parameters, string ifMatch, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.UpdateWithHttpMessagesAsync(resourceGroupName, serviceName, backendId, parameters, ifMatch, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Updates an existing backend. /// </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='backendId'> /// Identifier of the Backend entity. Must be unique in the current API /// Management service instance. /// </param> /// <param name='parameters'> /// Update parameters. /// </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> public static BackendContract Update(this IBackendOperations operations, string resourceGroupName, string serviceName, string backendId, BackendUpdateParameters parameters, string ifMatch) { return(operations.UpdateAsync(resourceGroupName, serviceName, backendId, parameters, ifMatch).GetAwaiter().GetResult()); }
/// <summary> /// Updates an existing backend. /// </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='backendid'> /// Identifier of the Backend entity. Must be unique in the current API /// Management service instance. /// </param> /// <param name='parameters'> /// Update parameters. /// </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 UpdateAsync(this IBackendOperations operations, string resourceGroupName, string serviceName, string backendid, BackendUpdateParameters parameters, string ifMatch, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.UpdateWithHttpMessagesAsync(resourceGroupName, serviceName, backendid, parameters, ifMatch, null, cancellationToken).ConfigureAwait(false)).Dispose(); }
/// <summary> /// Updates an existing backend. /// </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='backendid'> /// Identifier of the Backend entity. Must be unique in the current API /// Management service instance. /// </param> /// <param name='parameters'> /// Update parameters. /// </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> public static void Update(this IBackendOperations operations, string resourceGroupName, string serviceName, string backendid, BackendUpdateParameters parameters, string ifMatch) { operations.UpdateAsync(resourceGroupName, serviceName, backendid, parameters, ifMatch).GetAwaiter().GetResult(); }