public static RegisterInstanceResponse Unmarshall(UnmarshallerContext _ctx)
        {
            RegisterInstanceResponse registerInstanceResponse = new RegisterInstanceResponse();

            registerInstanceResponse.HttpResponse = _ctx.HttpResponse;
            registerInstanceResponse.RequestId    = _ctx.StringValue("RegisterInstance.RequestId");
            registerInstanceResponse.ErrorCode    = _ctx.StringValue("RegisterInstance.ErrorCode");
            registerInstanceResponse.ErrorMessage = _ctx.StringValue("RegisterInstance.ErrorMessage");
            registerInstanceResponse.Success      = _ctx.BooleanValue("RegisterInstance.Success");

            return(registerInstanceResponse);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Unmarshaller the response from the service to the response class.
        /// </summary>
        /// <param name="context"></param>
        /// <returns></returns>
        public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context)
        {
            RegisterInstanceResponse response = new RegisterInstanceResponse();

            context.Read();
            int targetDepth = context.CurrentDepth;

            while (context.ReadAtDepth(targetDepth))
            {
                if (context.TestExpression("InstanceId", targetDepth))
                {
                    var unmarshaller = StringUnmarshaller.Instance;
                    response.InstanceId = unmarshaller.Unmarshall(context);
                    continue;
                }
            }

            return(response);
        }