/// <summary> /// <para>Confirm the creation of a hosted connection on an interconnect.</para> <para>Upon creation, the hosted connection is initially in the /// 'Ordering' state, and will remain in this state until the owner calls ConfirmConnection to confirm creation of the hosted connection.</para> /// </summary> /// /// <param name="confirmConnectionRequest">Container for the necessary parameters to execute the ConfirmConnection service method on /// AmazonDirectConnect.</param> /// /// <returns>The response from the ConfirmConnection service method, as returned by AmazonDirectConnect.</returns> /// /// <exception cref="T:Amazon.DirectConnect.Model.DirectConnectServerException" /> /// <exception cref="T:Amazon.DirectConnect.Model.DirectConnectClientException" /> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> public Task <ConfirmConnectionResponse> ConfirmConnectionAsync(ConfirmConnectionRequest confirmConnectionRequest, CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new ConfirmConnectionRequestMarshaller(); var unmarshaller = ConfirmConnectionResponseUnmarshaller.GetInstance(); return(Invoke <IRequest, ConfirmConnectionRequest, ConfirmConnectionResponse>(confirmConnectionRequest, marshaller, unmarshaller, signer, cancellationToken)); }
internal ConfirmConnectionResponse ConfirmConnection(ConfirmConnectionRequest request) { var marshaller = new ConfirmConnectionRequestMarshaller(); var unmarshaller = ConfirmConnectionResponseUnmarshaller.Instance; return(Invoke <ConfirmConnectionRequest, ConfirmConnectionResponse>(request, marshaller, unmarshaller)); }
/// <summary> /// Initiates the asynchronous execution of the ConfirmConnection operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the ConfirmConnection 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 <ConfirmConnectionResponse> ConfirmConnectionAsync(ConfirmConnectionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new ConfirmConnectionRequestMarshaller(); var unmarshaller = ConfirmConnectionResponseUnmarshaller.Instance; return(InvokeAsync <ConfirmConnectionRequest, ConfirmConnectionResponse>(request, marshaller, unmarshaller, cancellationToken)); }
internal ConfirmConnectionResponse ConfirmConnection(ConfirmConnectionRequest request) { var task = ConfirmConnectionAsync(request); try { return(task.Result); } catch (AggregateException e) { ExceptionDispatchInfo.Capture(e.InnerException).Throw(); return(null); } }