public static DescribeImageSupportInstanceTypesResponse Unmarshall(UnmarshallerContext _ctx)
        {
            DescribeImageSupportInstanceTypesResponse describeImageSupportInstanceTypesResponse = new DescribeImageSupportInstanceTypesResponse();

            describeImageSupportInstanceTypesResponse.HttpResponse = _ctx.HttpResponse;
            describeImageSupportInstanceTypesResponse.RequestId    = _ctx.StringValue("DescribeImageSupportInstanceTypes.RequestId");
            describeImageSupportInstanceTypesResponse.RegionId     = _ctx.StringValue("DescribeImageSupportInstanceTypes.RegionId");
            describeImageSupportInstanceTypesResponse.ImageId      = _ctx.StringValue("DescribeImageSupportInstanceTypes.ImageId");

            List <DescribeImageSupportInstanceTypesResponse.DescribeImageSupportInstanceTypes_InstanceType> describeImageSupportInstanceTypesResponse_instanceTypes = new List <DescribeImageSupportInstanceTypesResponse.DescribeImageSupportInstanceTypes_InstanceType>();

            for (int i = 0; i < _ctx.Length("DescribeImageSupportInstanceTypes.InstanceTypes.Length"); i++)
            {
                DescribeImageSupportInstanceTypesResponse.DescribeImageSupportInstanceTypes_InstanceType instanceType = new DescribeImageSupportInstanceTypesResponse.DescribeImageSupportInstanceTypes_InstanceType();
                instanceType.InstanceTypeId     = _ctx.StringValue("DescribeImageSupportInstanceTypes.InstanceTypes[" + i + "].InstanceTypeId");
                instanceType.CpuCoreCount       = _ctx.IntegerValue("DescribeImageSupportInstanceTypes.InstanceTypes[" + i + "].CpuCoreCount");
                instanceType.MemorySize         = _ctx.FloatValue("DescribeImageSupportInstanceTypes.InstanceTypes[" + i + "].MemorySize");
                instanceType.InstanceTypeFamily = _ctx.StringValue("DescribeImageSupportInstanceTypes.InstanceTypes[" + i + "].InstanceTypeFamily");

                describeImageSupportInstanceTypesResponse_instanceTypes.Add(instanceType);
            }
            describeImageSupportInstanceTypesResponse.InstanceTypes = describeImageSupportInstanceTypesResponse_instanceTypes;

            return(describeImageSupportInstanceTypesResponse);
        }
Example #2
0
        public static DescribeImageSupportInstanceTypesResponse Unmarshall(UnmarshallerContext context)
        {
            DescribeImageSupportInstanceTypesResponse describeImageSupportInstanceTypesResponse = new DescribeImageSupportInstanceTypesResponse()
            {
                HttpResponse = context.HttpResponse,
                RequestId    = context.StringValue("DescribeImageSupportInstanceTypes.RequestId"),
                RegionId     = context.StringValue("DescribeImageSupportInstanceTypes.RegionId"),
                ImageId      = context.StringValue("DescribeImageSupportInstanceTypes.ImageId")
            };
            List <DescribeImageSupportInstanceTypesResponse.InstanceType> instanceTypes = new List <DescribeImageSupportInstanceTypesResponse.InstanceType>();

            for (int i = 0; i < context.Length("DescribeImageSupportInstanceTypes.InstanceTypes.Length"); i++)
            {
                DescribeImageSupportInstanceTypesResponse.InstanceType instanceType = new DescribeImageSupportInstanceTypesResponse.InstanceType()
                {
                    InstanceTypeId     = context.StringValue($"DescribeImageSupportInstanceTypes.InstanceTypes[{i}].InstanceTypeId"),
                    CpuCoreCount       = context.IntegerValue($"DescribeImageSupportInstanceTypes.InstanceTypes[{i}].CpuCoreCount"),
                    MemorySize         = context.FloatValue($"DescribeImageSupportInstanceTypes.InstanceTypes[{i}].MemorySize"),
                    InstanceTypeFamily = context.StringValue($"DescribeImageSupportInstanceTypes.InstanceTypes[{i}].InstanceTypeFamily")
                };
                instanceTypes.Add(instanceType);
            }
            describeImageSupportInstanceTypesResponse.InstanceTypes = instanceTypes;

            return(describeImageSupportInstanceTypesResponse);
        }