/// <summary> /// Initiates the asynchronous execution of the DeleteDistribution operation. /// <seealso cref="Amazon.CloudFront.IAmazonCloudFront"/> /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the DeleteDistribution operation.</param> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> /// <returns>The task object representing the asynchronous operation.</returns> public Task <DeleteDistributionResponse> DeleteDistributionAsync(DeleteDistributionRequest request, CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new DeleteDistributionRequestMarshaller(); var unmarshaller = DeleteDistributionResponseUnmarshaller.Instance; return(Invoke <IRequest, DeleteDistributionRequest, DeleteDistributionResponse>(request, marshaller, unmarshaller, signer, cancellationToken)); }
internal DeleteDistributionResponse DeleteDistribution(DeleteDistributionRequest request) { var marshaller = new DeleteDistributionRequestMarshaller(); var unmarshaller = DeleteDistributionResponseUnmarshaller.Instance; return(Invoke <DeleteDistributionRequest, DeleteDistributionResponse>(request, marshaller, unmarshaller)); }
internal DeleteDistributionResponse DeleteDistribution(DeleteDistributionRequest request) { var task = DeleteDistributionAsync(request); try { return(task.Result); } catch (AggregateException e) { ExceptionDispatchInfo.Capture(e.InnerException).Throw(); return(null); } }
public DeleteDistributionResponse DeleteDistribution(DeleteDistributionRequest request) { if (request == null) { throw new ArgumentNullException("request", "The DeleteDistributionRequest specified is null!"); } if (!request.IsSetId()) { throw new ArgumentNullException("request", "The Distribution Id specified is null or empty!"); } if (!request.IsSetETag()) { throw new ArgumentNullException("request", "The Distribution ETag specified is null or empty!"); } return(this.Invoke <DeleteDistributionResponse>(this.ConvertDeleteDistribution(request), request.Headers)); }
public JsonResult DeleteDistribution(DeleteDistributionRequest request) { return(Json(b.DeleteDistribution(request))); }
private IDictionary <CloudFrontQueryParameter, string> ConvertDeleteDistribution(DeleteDistributionRequest request) { IDictionary <CloudFrontQueryParameter, string> parameters = new Dictionary <CloudFrontQueryParameter, string>(5); parameters.Add(CloudFrontQueryParameter.Verb, CloudFrontConstants.DeleteVerb); parameters.Add(CloudFrontQueryParameter.Action, "DeleteDistribution"); parameters.Add(CloudFrontQueryParameter.Id, request.Id); request.Headers["If-Match"] = request.ETag; this.AddCloudFrontQueryParameters(parameters, request.Headers); return(parameters); }
public DeleteDistributionResponse DeleteDistribution(DeleteDistributionRequest reg) { return(disbll.DeleteDistribution(reg)); }
/// <summary> /// 配送删除 /// </summary> /// <returns></returns> public DeleteDistributionResponse DeleteDistribution(DeleteDistributionRequest ids) { return(ApiRequestHelper.Post <DeleteDistributionRequest, DeleteDistributionResponse>(ids)); }