/// <summary> /// Initiates the asynchronous execution of the DescribeSnapshotAttribute operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the DescribeSnapshotAttribute 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<DescribeSnapshotAttributeResponse> DescribeSnapshotAttributeAsync(DescribeSnapshotAttributeRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new DescribeSnapshotAttributeRequestMarshaller(); var unmarshaller = DescribeSnapshotAttributeResponseUnmarshaller.Instance; return InvokeAsync<DescribeSnapshotAttributeRequest,DescribeSnapshotAttributeResponse>(request, marshaller, unmarshaller, cancellationToken); }
public void DescribeSnapshotAttributeMarshallTest() { var operation = service_model.FindOperation("DescribeSnapshotAttribute"); var request = InstantiateClassGenerator.Execute<DescribeSnapshotAttributeRequest>(); var marshaller = new DescribeSnapshotAttributeRequestMarshaller(); var internalRequest = marshaller.Marshall(request); var validator = new AWSQueryValidator(internalRequest.Parameters, request, service_model, operation); validator.Validate(); var payloadResponse = new XmlSampleGenerator(service_model, operation).Execute(); UnmarshallerContext context = new EC2UnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, new WebResponseData()); var response = DescribeSnapshotAttributeResponseUnmarshaller.Instance.Unmarshall(context) as DescribeSnapshotAttributeResponse; InstantiateClassGenerator.ValidateObjectFullyInstantiated(response); }
/// <summary> /// Describes the specified attribute of the specified snapshot. You can specify only /// one attribute at a time. /// /// /// <para> /// For more information about EBS snapshots, see <a href='http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSSnapshots.html'>Amazon /// EBS Snapshots</a> in the <i>Amazon Elastic Compute Cloud User Guide</i>. /// </para> /// </summary> /// <param name="request">Container for the necessary parameters to execute the DescribeSnapshotAttribute service method.</param> /// /// <returns>The response from the DescribeSnapshotAttribute service method, as returned by EC2.</returns> public DescribeSnapshotAttributeResponse DescribeSnapshotAttribute(DescribeSnapshotAttributeRequest request) { var marshaller = new DescribeSnapshotAttributeRequestMarshaller(); var unmarshaller = DescribeSnapshotAttributeResponseUnmarshaller.Instance; return Invoke<DescribeSnapshotAttributeRequest,DescribeSnapshotAttributeResponse>(request, marshaller, unmarshaller); }
/// <summary> /// Initiates the asynchronous execution of the DescribeSnapshotAttribute operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the DescribeSnapshotAttribute operation on AmazonEC2Client.</param> /// <param name="callback">An AsyncCallback delegate that is invoked when the operation completes.</param> /// <param name="state">A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback /// procedure using the AsyncState property.</param> /// /// <returns>An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndDescribeSnapshotAttribute /// operation.</returns> public IAsyncResult BeginDescribeSnapshotAttribute(DescribeSnapshotAttributeRequest request, AsyncCallback callback, object state) { var marshaller = new DescribeSnapshotAttributeRequestMarshaller(); var unmarshaller = DescribeSnapshotAttributeResponseUnmarshaller.Instance; return BeginInvoke<DescribeSnapshotAttributeRequest>(request, marshaller, unmarshaller, callback, state); }
IAsyncResult invokeDescribeSnapshotAttribute(DescribeSnapshotAttributeRequest describeSnapshotAttributeRequest, AsyncCallback callback, object state, bool synchronized) { IRequest irequest = new DescribeSnapshotAttributeRequestMarshaller().Marshall(describeSnapshotAttributeRequest); var unmarshaller = DescribeSnapshotAttributeResponseUnmarshaller.GetInstance(); AsyncResult result = new AsyncResult(irequest, callback, state, synchronized, signer, unmarshaller); Invoke(result); return result; }
/// <summary> /// <para>Describes an attribute of the specified snapshot. You can specify only one attribute at a time.</para> <para>For more information /// about Amazon EBS snapshots, see <a href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSSnapshots.html">Amazon EBS Snapshots</a> in /// the <i>Amazon Elastic Compute Cloud User Guide</i> .</para> /// </summary> /// /// <param name="describeSnapshotAttributeRequest">Container for the necessary parameters to execute the DescribeSnapshotAttribute service /// method on AmazonEC2.</param> /// /// <returns>The response from the DescribeSnapshotAttribute service method, as returned by AmazonEC2.</returns> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> public Task<DescribeSnapshotAttributeResponse> DescribeSnapshotAttributeAsync(DescribeSnapshotAttributeRequest describeSnapshotAttributeRequest, CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new DescribeSnapshotAttributeRequestMarshaller(); var unmarshaller = DescribeSnapshotAttributeResponseUnmarshaller.GetInstance(); return Invoke<IRequest, DescribeSnapshotAttributeRequest, DescribeSnapshotAttributeResponse>(describeSnapshotAttributeRequest, marshaller, unmarshaller, signer, cancellationToken); }
/// <summary> /// Initiates the asynchronous execution of the DescribeSnapshotAttribute operation. /// <seealso cref="Amazon.EC2.IAmazonEC2.DescribeSnapshotAttribute"/> /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the DescribeSnapshotAttribute 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 async Task<DescribeSnapshotAttributeResponse> DescribeSnapshotAttributeAsync(DescribeSnapshotAttributeRequest request, CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new DescribeSnapshotAttributeRequestMarshaller(); var unmarshaller = DescribeSnapshotAttributeResponseUnmarshaller.GetInstance(); var response = await Invoke<IRequest, DescribeSnapshotAttributeRequest, DescribeSnapshotAttributeResponse>(request, marshaller, unmarshaller, signer, cancellationToken) .ConfigureAwait(continueOnCapturedContext: false); return response; }