public static RegionUnmarshaller GetInstance() { if (instance == null) { instance = new RegionUnmarshaller(); } return(instance); }
public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context) { DescribeRegionsResponse response = new DescribeRegionsResponse(); int targetDepth = 2; while (context.Read()) { if (context.IsStartElement || context.IsAttribute) { if (context.TestExpression("regionInfo/item", targetDepth)) { response.Regions.Add(RegionUnmarshaller.GetInstance().Unmarshall(context)); continue; } } } return(response); }