本文整理汇总了C#中Amazon.Runtime.Internal.Transform.XmlUnmarshallerContext.TestExpression方法的典型用法代码示例。如果您正苦于以下问题:C# XmlUnmarshallerContext.TestExpression方法的具体用法?C# XmlUnmarshallerContext.TestExpression怎么用?C# XmlUnmarshallerContext.TestExpression使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Amazon.Runtime.Internal.Transform.XmlUnmarshallerContext
的用法示例。
在下文中一共展示了XmlUnmarshallerContext.TestExpression方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Unmarshall
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
ModifyEventSubscriptionResponse response = new ModifyEventSubscriptionResponse();
while (context.Read())
{
if (context.IsStartElement)
{
if(context.TestExpression("ModifyEventSubscriptionResult", 2))
{
UnmarshallResult(context,response);
continue;
}
if (context.TestExpression("ResponseMetadata", 2))
{
response.ResponseMetadata = ResponseMetadataUnmarshaller.GetInstance().Unmarshall(context);
}
}
}
return response;
}
示例2: UnmarshallResult
private static void UnmarshallResult(XmlUnmarshallerContext context, DescribeClusterParametersResponse response)
{
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth += 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("Marker", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.Marker = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("Parameters/Parameter", targetDepth))
{
var unmarshaller = ParameterUnmarshaller.Instance;
var item = unmarshaller.Unmarshall(context);
response.Parameters.Add(item);
continue;
}
}
}
return;
}
示例3: Unmarshall
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
DescribeInstanceStatusResponse response = new DescribeInstanceStatusResponse();
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth = 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("instanceStatusSet/item", targetDepth))
{
var unmarshaller = InstanceStatusUnmarshaller.Instance;
var item = unmarshaller.Unmarshall(context);
response.InstanceStatuses.Add(item);
continue;
}
if (context.TestExpression("nextToken", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.NextToken = unmarshaller.Unmarshall(context);
continue;
}
}
}
return response;
}
示例4: Unmarshall
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
AuthorizeCacheSecurityGroupIngressResponse response = new AuthorizeCacheSecurityGroupIngressResponse();
while (context.Read())
{
if (context.IsStartElement)
{
if(context.TestExpression("AuthorizeCacheSecurityGroupIngressResult", 2))
{
UnmarshallResult(context,response);
continue;
}
if (context.TestExpression("ResponseMetadata", 2))
{
response.ResponseMetadata = ResponseMetadataUnmarshaller.GetInstance().Unmarshall(context);
}
}
}
return response;
}
开发者ID:scopely,项目名称:aws-sdk-net,代码行数:27,代码来源:AuthorizeCacheSecurityGroupIngressResponseUnmarshaller.cs
示例5: Unmarshall
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
CreateCacheParameterGroupResponse response = new CreateCacheParameterGroupResponse();
while (context.Read())
{
if (context.IsStartElement)
{
if(context.TestExpression("CreateCacheParameterGroupResult", 2))
{
UnmarshallResult(context,response);
continue;
}
if (context.TestExpression("ResponseMetadata", 2))
{
response.ResponseMetadata = ResponseMetadataUnmarshaller.GetInstance().Unmarshall(context);
}
}
}
return response;
}
示例6: Unmarshall
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
DescribeVolumeStatusResponse response = new DescribeVolumeStatusResponse();
int targetDepth = 2;
while (context.Read())
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("volumeStatusSet/item", targetDepth))
{
response.VolumeStatuses.Add(VolumeStatusItemUnmarshaller.GetInstance().Unmarshall(context));
continue;
}
if (context.TestExpression("nextToken", targetDepth))
{
response.NextToken = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
}
}
return response;
}
示例7: Unmarshall
/// <summary>
/// Unmarshaller the response from the service to the response class.
/// </summary>
/// <param name="context"></param>
/// <returns></returns>
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
GetIdentityMailFromDomainAttributesResponse response = new GetIdentityMailFromDomainAttributesResponse();
context.Read();
int targetDepth = context.CurrentDepth;
while (context.ReadAtDepth(targetDepth))
{
if (context.IsStartElement)
{
if(context.TestExpression("GetIdentityMailFromDomainAttributesResult", 2))
{
UnmarshallResult(context, response);
continue;
}
if (context.TestExpression("ResponseMetadata", 2))
{
response.ResponseMetadata = ResponseMetadataUnmarshaller.Instance.Unmarshall(context);
}
}
}
return response;
}
示例8: Unmarshall
/// <summary>
/// Unmarshaller the response from the service to the response class.
/// </summary>
/// <param name="context"></param>
/// <returns></returns>
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
ModifyVpcPeeringConnectionOptionsResponse response = new ModifyVpcPeeringConnectionOptionsResponse();
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth = 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("accepterPeeringConnectionOptions", targetDepth))
{
var unmarshaller = PeeringConnectionOptionsUnmarshaller.Instance;
response.AccepterPeeringConnectionOptions = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("requesterPeeringConnectionOptions", targetDepth))
{
var unmarshaller = PeeringConnectionOptionsUnmarshaller.Instance;
response.RequesterPeeringConnectionOptions = unmarshaller.Unmarshall(context);
continue;
}
}
}
return response;
}
示例9: Unmarshall
/// <summary>
/// Unmarshaller the response from the service to the response class.
/// </summary>
/// <param name="context"></param>
/// <returns></returns>
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
AssociateSubnetCidrBlockResponse response = new AssociateSubnetCidrBlockResponse();
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth = 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("ipv6CidrBlockAssociation", targetDepth))
{
var unmarshaller = SubnetIpv6CidrBlockAssociationUnmarshaller.Instance;
response.Ipv6CidrBlockAssociation = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("subnetId", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.SubnetId = unmarshaller.Unmarshall(context);
continue;
}
}
}
return response;
}
示例10: UnmarshallResult
private static void UnmarshallResult(XmlUnmarshallerContext context, ModifyClusterParameterGroupResponse response)
{
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth += 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("ParameterGroupName", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.ParameterGroupName = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("ParameterGroupStatus", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.ParameterGroupStatus = unmarshaller.Unmarshall(context);
continue;
}
}
}
return;
}
开发者ID:jeffersonjhunt,项目名称:aws-sdk-net,代码行数:31,代码来源:ModifyClusterParameterGroupResponseUnmarshaller.cs
示例11: Unmarshall
/// <summary>
/// Unmarshaller the response from the service to the response class.
/// </summary>
/// <param name="context"></param>
/// <returns></returns>
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
RestoreAddressToClassicResponse response = new RestoreAddressToClassicResponse();
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth = 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("publicIp", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.PublicIp = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("status", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.Status = unmarshaller.Unmarshall(context);
continue;
}
}
}
return response;
}
示例12: UnmarshallResult
private static void UnmarshallResult(XmlUnmarshallerContext context,CreateJobResponse response)
{
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth += 2;
while (context.Read())
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("JobId", targetDepth))
{
response.JobId = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
if (context.TestExpression("JobType", targetDepth))
{
response.JobType = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
if (context.TestExpression("AwsShippingAddress", targetDepth))
{
response.AwsShippingAddress = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
if (context.TestExpression("Signature", targetDepth))
{
response.Signature = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
if (context.TestExpression("SignatureFileContents", targetDepth))
{
response.SignatureFileContents = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
if (context.TestExpression("WarningMessage", targetDepth))
{
response.WarningMessage = StringUnmarshaller.GetInstance().Unmarshall(context);
continue;
}
}
else if (context.IsEndElement && context.CurrentDepth < originalDepth)
{
return;
}
}
return;
}
示例13: UnmarshallResult
private static void UnmarshallResult(XmlUnmarshallerContext context, ListJobsResponse response)
{
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth += 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("IsTruncated", targetDepth))
{
var unmarshaller = BoolUnmarshaller.Instance;
response.IsTruncated = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("Jobs/member", targetDepth))
{
var unmarshaller = JobUnmarshaller.Instance;
var item = unmarshaller.Unmarshall(context);
response.Jobs.Add(item);
continue;
}
}
}
return;
}
示例14: Unmarshall
/// <summary>
/// Unmarshaller the response from the service to the response class.
/// </summary>
/// <param name="context"></param>
/// <returns></returns>
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
ConfirmProductInstanceResponse response = new ConfirmProductInstanceResponse();
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth = 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("ownerId", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.OwnerId = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("return", targetDepth))
{
var unmarshaller = BoolUnmarshaller.Instance;
response.Return = unmarshaller.Unmarshall(context);
continue;
}
}
}
return response;
}
示例15: UnmarshallResult
private static void UnmarshallResult(XmlUnmarshallerContext context, DescribeConfigurationOptionsResponse response)
{
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth += 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("Options/member", targetDepth))
{
var unmarshaller = ConfigurationOptionDescriptionUnmarshaller.Instance;
var item = unmarshaller.Unmarshall(context);
response.Options.Add(item);
continue;
}
if (context.TestExpression("SolutionStackName", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.SolutionStackName = unmarshaller.Unmarshall(context);
continue;
}
}
}
return;
}