/// <summary> /// Initiates the asynchronous execution of the TestDNSAnswer operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the TestDNSAnswer operation on AmazonRoute53Client.</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 EndTestDNSAnswer /// operation.</returns> public IAsyncResult BeginTestDNSAnswer(TestDNSAnswerRequest request, AsyncCallback callback, object state) { var marshaller = new TestDNSAnswerRequestMarshaller(); var unmarshaller = TestDNSAnswerResponseUnmarshaller.Instance; return BeginInvoke<TestDNSAnswerRequest>(request, marshaller, unmarshaller, callback, state); }
public void TestDNSAnswerMarshallTest() { var operation = service_model.FindOperation("TestDNSAnswer"); var request = InstantiateClassGenerator.Execute<TestDNSAnswerRequest>(); var marshaller = new TestDNSAnswerRequestMarshaller(); var internalRequest = marshaller.Marshall(request); RequestValidator.Validate("TestDNSAnswer", request, internalRequest, service_model); var webResponse = new WebResponseData { Headers = { {"x-amzn-RequestId", Guid.NewGuid().ToString()}, {"x-amz-crc32","0"} } }; var payloadResponse = new XmlSampleGenerator(service_model, operation).Execute(); var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, webResponse); ResponseUnmarshaller unmarshaller = TestDNSAnswerResponseUnmarshaller.Instance; var response = unmarshaller.Unmarshall(context) as TestDNSAnswerResponse; InstantiateClassGenerator.ValidateObjectFullyInstantiated(response); }
/// <summary> /// Gets the value that Amazon Route 53 returns in response to a DNS request for a specified /// record name and type. You can optionally specify the IP address of a DNS resolver, /// an EDNS0 client subnet IP address, and a subnet mask. /// </summary> /// <param name="request">Container for the necessary parameters to execute the TestDNSAnswer service method.</param> /// /// <returns>The response from the TestDNSAnswer service method, as returned by Route53.</returns> /// <exception cref="Amazon.Route53.Model.InvalidInputException"> /// The input is not valid. /// </exception> /// <exception cref="Amazon.Route53.Model.NoSuchHostedZoneException"> /// No hosted zone exists with the ID that you specified. /// </exception> public TestDNSAnswerResponse TestDNSAnswer(TestDNSAnswerRequest request) { var marshaller = new TestDNSAnswerRequestMarshaller(); var unmarshaller = TestDNSAnswerResponseUnmarshaller.Instance; return Invoke<TestDNSAnswerRequest,TestDNSAnswerResponse>(request, marshaller, unmarshaller); }
/// <summary> /// Initiates the asynchronous execution of the TestDNSAnswer operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the TestDNSAnswer 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<TestDNSAnswerResponse> TestDNSAnswerAsync(TestDNSAnswerRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new TestDNSAnswerRequestMarshaller(); var unmarshaller = TestDNSAnswerResponseUnmarshaller.Instance; return InvokeAsync<TestDNSAnswerRequest,TestDNSAnswerResponse>(request, marshaller, unmarshaller, cancellationToken); }