/// <summary> /// Unmarshaller the response from the service to the response class. /// </summary> /// <param name="context"></param> /// <returns></returns> public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context) { UpdateBrokerResponse response = new UpdateBrokerResponse(); context.Read(); int targetDepth = context.CurrentDepth; while (context.ReadAtDepth(targetDepth)) { if (context.TestExpression("brokerId", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.BrokerId = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("configuration", targetDepth)) { var unmarshaller = ConfigurationIdUnmarshaller.Instance; response.Configuration = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("logs", targetDepth)) { var unmarshaller = LogsUnmarshaller.Instance; response.Logs = unmarshaller.Unmarshall(context); continue; } } return(response); }
/// <summary> /// Unmarshaller the response from the service to the response class. /// </summary> /// <param name="context"></param> /// <returns></returns> public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context) { UpdateBrokerResponse response = new UpdateBrokerResponse(); context.Read(); int targetDepth = context.CurrentDepth; while (context.ReadAtDepth(targetDepth)) { if (context.TestExpression("autoMinorVersionUpgrade", targetDepth)) { var unmarshaller = BoolUnmarshaller.Instance; response.AutoMinorVersionUpgrade = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("brokerId", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.BrokerId = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("configuration", targetDepth)) { var unmarshaller = ConfigurationIdUnmarshaller.Instance; response.Configuration = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("engineVersion", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.EngineVersion = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("hostInstanceType", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.HostInstanceType = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("logs", targetDepth)) { var unmarshaller = LogsUnmarshaller.Instance; response.Logs = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("securityGroups", targetDepth)) { var unmarshaller = new ListUnmarshaller <string, StringUnmarshaller>(StringUnmarshaller.Instance); response.SecurityGroups = unmarshaller.Unmarshall(context); continue; } } return(response); }