/// <summary> /// Initiates the asynchronous execution of the GetStreamingDistribution operation. /// <seealso cref="Amazon.CloudFront.IAmazonCloudFront"/> /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the GetStreamingDistribution 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 <GetStreamingDistributionResponse> GetStreamingDistributionAsync(GetStreamingDistributionRequest request, CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new GetStreamingDistributionRequestMarshaller(); var unmarshaller = GetStreamingDistributionResponseUnmarshaller.Instance; return(Invoke <IRequest, GetStreamingDistributionRequest, GetStreamingDistributionResponse>(request, marshaller, unmarshaller, signer, cancellationToken)); }
internal GetStreamingDistributionResponse GetStreamingDistribution(GetStreamingDistributionRequest request) { var marshaller = new GetStreamingDistributionRequestMarshaller(); var unmarshaller = GetStreamingDistributionResponseUnmarshaller.Instance; return(Invoke <GetStreamingDistributionRequest, GetStreamingDistributionResponse>(request, marshaller, unmarshaller)); }
internal GetStreamingDistributionResponse GetStreamingDistribution(GetStreamingDistributionRequest request) { var task = GetStreamingDistributionAsync(request); try { return(task.Result); } catch (AggregateException e) { ExceptionDispatchInfo.Capture(e.InnerException).Throw(); return(null); } }