当前位置: 首页>>代码示例>>C#>>正文


C# TestTools.XmlSampleGenerator类代码示例

本文整理汇总了C#中AWSSDK_DotNet35.UnitTests.TestTools.XmlSampleGenerator的典型用法代码示例。如果您正苦于以下问题:C# XmlSampleGenerator类的具体用法?C# XmlSampleGenerator怎么用?C# XmlSampleGenerator使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


XmlSampleGenerator类属于AWSSDK_DotNet35.UnitTests.TestTools命名空间,在下文中一共展示了XmlSampleGenerator类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: CreateCloudFrontOriginAccessIdentityMarshallTest

        public void CreateCloudFrontOriginAccessIdentityMarshallTest()
        {
            var operation = service_model.FindOperation("CreateCloudFrontOriginAccessIdentity");

            var request = InstantiateClassGenerator.Execute<CreateCloudFrontOriginAccessIdentityRequest>();
            var marshaller = new CreateCloudFrontOriginAccessIdentityRequestMarshaller();

            var internalRequest = marshaller.Marshall(request);
            RequestValidator.Validate("CreateCloudFrontOriginAccessIdentity", request, internalRequest, service_model);            

            var webResponse = new WebResponseData
            {
                Headers = {
                    {"ETag","ETag_Value"},
                    {"Location","Location_Value"},
                    {"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 = CreateCloudFrontOriginAccessIdentityResponseUnmarshaller.Instance;
            var response = unmarshaller.Unmarshall(context)
                as CreateCloudFrontOriginAccessIdentityResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:aws,项目名称:aws-sdk-net,代码行数:27,代码来源:CloudFrontMarshallingTests.cs

示例2: AssociateVPCWithHostedZoneMarshallTest

        public void AssociateVPCWithHostedZoneMarshallTest()
        {
            var operation = service_model.FindOperation("AssociateVPCWithHostedZone");

            var request = InstantiateClassGenerator.Execute<AssociateVPCWithHostedZoneRequest>();
            var marshaller = new AssociateVPCWithHostedZoneRequestMarshaller();

            var internalRequest = marshaller.Marshall(request);
            RequestValidator.Validate("AssociateVPCWithHostedZone", 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 = AssociateVPCWithHostedZoneResponseUnmarshaller.Instance;
            var response = unmarshaller.Unmarshall(context)
                as AssociateVPCWithHostedZoneResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:aws,项目名称:aws-sdk-net,代码行数:25,代码来源:Route53MarshallingTests.cs

示例3: ContinueUpdateRollbackMarshallTest

        public void ContinueUpdateRollbackMarshallTest()
        {
            var operation = service_model.FindOperation("ContinueUpdateRollback");

            var request = InstantiateClassGenerator.Execute<ContinueUpdateRollbackRequest>();
            var marshaller = new ContinueUpdateRollbackRequestMarshaller();
            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();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = ContinueUpdateRollbackResponseUnmarshaller.Instance.Unmarshall(context)
                as ContinueUpdateRollbackResponse;
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);
        }
开发者ID:srz2,项目名称:aws-sdk-net,代码行数:16,代码来源:CloudFormationMarshallingTests.cs

示例4: AcceptVpcPeeringConnectionMarshallTest

        public void AcceptVpcPeeringConnectionMarshallTest()
        {
            var operation = service_model.FindOperation("AcceptVpcPeeringConnection");

            var request = InstantiateClassGenerator.Execute<AcceptVpcPeeringConnectionRequest>();
            var marshaller = new AcceptVpcPeeringConnectionRequestMarshaller();
            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 = AcceptVpcPeeringConnectionResponseUnmarshaller.Instance.Unmarshall(context)
                as AcceptVpcPeeringConnectionResponse;
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);
        }
开发者ID:jweyrich,项目名称:aws-sdk-net,代码行数:16,代码来源:EC2MarshallingTests.cs

示例5: AddSourceIdentifierToSubscriptionMarshallTest

        public void AddSourceIdentifierToSubscriptionMarshallTest()
        {
            var operation = service_model.FindOperation("AddSourceIdentifierToSubscription");

            var request = InstantiateClassGenerator.Execute<AddSourceIdentifierToSubscriptionRequest>();
            var marshaller = new AddSourceIdentifierToSubscriptionRequestMarshaller();
            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();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = AddSourceIdentifierToSubscriptionResponseUnmarshaller.Instance.Unmarshall(context)
                as AddSourceIdentifierToSubscriptionResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:yridesconix,项目名称:aws-sdk-net,代码行数:17,代码来源:RDSMarshallingTests.cs

示例6: AuthorizeClusterSecurityGroupIngressMarshallTest

        public void AuthorizeClusterSecurityGroupIngressMarshallTest()
        {
            var operation = service_model.FindOperation("AuthorizeClusterSecurityGroupIngress");

            var request = InstantiateClassGenerator.Execute<AuthorizeClusterSecurityGroupIngressRequest>();
            var marshaller = new AuthorizeClusterSecurityGroupIngressRequestMarshaller();
            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();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = AuthorizeClusterSecurityGroupIngressResponseUnmarshaller.Instance.Unmarshall(context)
                as AuthorizeClusterSecurityGroupIngressResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:JonathanHenson,项目名称:aws-sdk-net,代码行数:17,代码来源:RedshiftMarshallingTests.cs

示例7: DescribeScheduledInstanceAvailabilityMarshallTest

        public void DescribeScheduledInstanceAvailabilityMarshallTest()
        {
            var operation = service_model.FindOperation("DescribeScheduledInstanceAvailability");

            var request = InstantiateClassGenerator.Execute<DescribeScheduledInstanceAvailabilityRequest>();
            var marshaller = new DescribeScheduledInstanceAvailabilityRequestMarshaller();
            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 = DescribeScheduledInstanceAvailabilityResponseUnmarshaller.Instance.Unmarshall(context)
                as DescribeScheduledInstanceAvailabilityResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:aws,项目名称:aws-sdk-net,代码行数:17,代码来源:EC2MarshallingTests.cs

示例8: DescribeEnvironmentManagedActionsMarshallTest

        public void DescribeEnvironmentManagedActionsMarshallTest()
        {
            var operation = service_model.FindOperation("DescribeEnvironmentManagedActions");

            var request = InstantiateClassGenerator.Execute<DescribeEnvironmentManagedActionsRequest>();
            var marshaller = new DescribeEnvironmentManagedActionsRequestMarshaller();
            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();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = DescribeEnvironmentManagedActionsResponseUnmarshaller.Instance.Unmarshall(context)
                as DescribeEnvironmentManagedActionsResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:aws,项目名称:aws-sdk-net,代码行数:17,代码来源:ElasticBeanstalkMarshallingTests.cs

示例9: SetLoadBalancerPoliciesForBackendServerMarshallTest

        public void SetLoadBalancerPoliciesForBackendServerMarshallTest()
        {
            var operation = service_model.FindOperation("SetLoadBalancerPoliciesForBackendServer");

            var request = InstantiateClassGenerator.Execute<SetLoadBalancerPoliciesForBackendServerRequest>();
            var marshaller = new SetLoadBalancerPoliciesForBackendServerRequestMarshaller();
            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();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = SetLoadBalancerPoliciesForBackendServerResponseUnmarshaller.Instance.Unmarshall(context)
                as SetLoadBalancerPoliciesForBackendServerResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:borik,项目名称:aws-sdk-net,代码行数:17,代码来源:ElasticLoadBalancingMarshallingTests.cs

示例10: Generate

 string Generate(ServiceModel model, string operationName)
 {
     var operation = model.Operations.First(x => x.Name == operationName);
     var generator = new XmlSampleGenerator(model, operation);
     return generator.Execute();
 }
开发者ID:rajdotnet,项目名称:aws-sdk-net,代码行数:6,代码来源:XmlSampleGeneratorTests.cs

示例11: GetIdentityMailFromDomainAttributesMarshallTest

        public void GetIdentityMailFromDomainAttributesMarshallTest()
        {
            var operation = service_model.FindOperation("GetIdentityMailFromDomainAttributes");

            var request = InstantiateClassGenerator.Execute<GetIdentityMailFromDomainAttributesRequest>();
            var marshaller = new GetIdentityMailFromDomainAttributesRequestMarshaller();
            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();
            var context = new XmlUnmarshallerContext(Utils.CreateStreamFromString(payloadResponse), false, null);
            var response = GetIdentityMailFromDomainAttributesResponseUnmarshaller.Instance.Unmarshall(context)
                as GetIdentityMailFromDomainAttributesResponse;   
            InstantiateClassGenerator.ValidateObjectFullyInstantiated(response);       
        }
开发者ID:aws,项目名称:aws-sdk-net,代码行数:17,代码来源:SimpleEmailServiceMarshallingTests.cs


注:本文中的AWSSDK_DotNet35.UnitTests.TestTools.XmlSampleGenerator类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。