Returns information about the DescribeUploadBuffer response and response metadata.
Inheritance: DescribeUploadBufferResult
       private static void UnmarshallResult(JsonUnmarshallerContext context,DescribeUploadBufferResponse response)
       {
         
           int originalDepth = context.CurrentDepth;
           int targetDepth = originalDepth + 1;
           while (context.Read())
           {
             
             if (context.TestExpression("GatewayARN", targetDepth))
             {
               context.Read();
               response.GatewayARN = StringUnmarshaller.GetInstance().Unmarshall(context);
               continue;
             }
 
             if (context.TestExpression("DiskIds", targetDepth))
             {
               context.Read();
               response.DiskIds = new List<String>();
                       StringUnmarshaller unmarshaller = StringUnmarshaller.GetInstance();
               while (context.Read())
               {
                 JsonToken token = context.CurrentTokenType;                
                 if (token == JsonToken.ArrayStart)
                 {
                   continue;
                 }
                 if (token == JsonToken.ArrayEnd)
                 {
                   break;
                 }
                  response.DiskIds.Add(unmarshaller.Unmarshall(context));
               }
               continue;
             }
 
             if (context.TestExpression("UploadBufferUsedInBytes", targetDepth))
             {
               context.Read();
               response.UploadBufferUsedInBytes = LongUnmarshaller.GetInstance().Unmarshall(context);
               continue;
             }
 
             if (context.TestExpression("UploadBufferAllocatedInBytes", targetDepth))
             {
               context.Read();
               response.UploadBufferAllocatedInBytes = LongUnmarshaller.GetInstance().Unmarshall(context);
               continue;
             }
 
               if (context.CurrentDepth <= originalDepth)
               {                   
                   return;
               }
           }
                       
           return;
       }                        
 public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context)
 {
   DescribeUploadBufferResponse response = new DescribeUploadBufferResponse();          
   
   context.Read();
   
   UnmarshallResult(context,response);
   return response;
 }
Esempio n. 3
0
        public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context)
        {
            DescribeUploadBufferResponse response = new DescribeUploadBufferResponse();

              context.Read();

              response.DescribeUploadBufferResult = DescribeUploadBufferResultUnmarshaller.GetInstance().Unmarshall(context);

              return response;
        }
       public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context)
       {
           DescribeUploadBufferResponse response = new DescribeUploadBufferResponse();       
         
           context.Read();
           int targetDepth = context.CurrentDepth;
           while (context.ReadAtDepth(targetDepth))
           {
             
             if (context.TestExpression("GatewayARN", targetDepth))
             {
               response.GatewayARN = StringUnmarshaller.GetInstance().Unmarshall(context);
               continue;
             }
 
             if (context.TestExpression("DiskIds", targetDepth))
             {
               
               var unmarshaller = new ListUnmarshaller<String,StringUnmarshaller>(
                   StringUnmarshaller.GetInstance());                  
               response.DiskIds = unmarshaller.Unmarshall(context);
               
               continue;
             }
 
             if (context.TestExpression("UploadBufferUsedInBytes", targetDepth))
             {
               response.UploadBufferUsedInBytes = LongUnmarshaller.GetInstance().Unmarshall(context);
               continue;
             }
 
             if (context.TestExpression("UploadBufferAllocatedInBytes", targetDepth))
             {
               response.UploadBufferAllocatedInBytes = LongUnmarshaller.GetInstance().Unmarshall(context);
               continue;
             }
 
           }
                       
           return response;
       }