public static DescribeVServerGroupAttributeResponse Unmarshall(UnmarshallerContext context) { DescribeVServerGroupAttributeResponse describeVServerGroupAttributeResponse = new DescribeVServerGroupAttributeResponse() { HttpResponse = context.HttpResponse, RequestId = context.StringValue("DescribeVServerGroupAttribute.RequestId"), VServerGroupId = context.StringValue("DescribeVServerGroupAttribute.VServerGroupId"), VServerGroupName = context.StringValue("DescribeVServerGroupAttribute.VServerGroupName") }; List <DescribeVServerGroupAttributeResponse.BackendServer> backendServers = new List <DescribeVServerGroupAttributeResponse.BackendServer>(); for (int i = 0; i < context.Length("DescribeVServerGroupAttribute.BackendServers.Length"); i++) { DescribeVServerGroupAttributeResponse.BackendServer backendServer = new DescribeVServerGroupAttributeResponse.BackendServer() { ServerId = context.StringValue($"DescribeVServerGroupAttribute.BackendServers[{i}].ServerId"), Port = context.IntegerValue($"DescribeVServerGroupAttribute.BackendServers[{i}].Port"), Weight = context.IntegerValue($"DescribeVServerGroupAttribute.BackendServers[{i}].Weight") }; backendServers.Add(backendServer); } describeVServerGroupAttributeResponse.BackendServers = backendServers; return(describeVServerGroupAttributeResponse); }
public static DescribeVServerGroupAttributeResponse Unmarshall(UnmarshallerContext context) { DescribeVServerGroupAttributeResponse describeVServerGroupAttributeResponse = new DescribeVServerGroupAttributeResponse(); describeVServerGroupAttributeResponse.HttpResponse = context.HttpResponse; describeVServerGroupAttributeResponse.RequestId = context.StringValue("DescribeVServerGroupAttribute.RequestId"); describeVServerGroupAttributeResponse.VServerGroupId = context.StringValue("DescribeVServerGroupAttribute.VServerGroupId"); describeVServerGroupAttributeResponse.VServerGroupName = context.StringValue("DescribeVServerGroupAttribute.VServerGroupName"); List<DescribeVServerGroupAttributeResponse.BackendServer> backendServers = new List<DescribeVServerGroupAttributeResponse.BackendServer>(); for (int i = 0; i < context.Length("DescribeVServerGroupAttribute.BackendServers.Length"); i++) { DescribeVServerGroupAttributeResponse.BackendServer backendServer = new DescribeVServerGroupAttributeResponse.BackendServer(); backendServer.ServerId = context.StringValue("DescribeVServerGroupAttribute.BackendServers["+ i +"].ServerId"); backendServer.Port = context.IntegerValue("DescribeVServerGroupAttribute.BackendServers["+ i +"].Port"); backendServer.Weight = context.IntegerValue("DescribeVServerGroupAttribute.BackendServers["+ i +"].Weight"); backendServers.Add(backendServer); } describeVServerGroupAttributeResponse.BackendServers = backendServers; return describeVServerGroupAttributeResponse; }