/// <summary> /// Unmarshaller the response from the service to the response class. /// </summary> /// <param name="context"></param> /// <returns></returns> public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context) { DescribeScheduleResponse response = new DescribeScheduleResponse(); context.Read(); int targetDepth = context.CurrentDepth; while (context.ReadAtDepth(targetDepth)) { if (context.TestExpression("nextToken", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.NextToken = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("scheduleActions", targetDepth)) { var unmarshaller = new ListUnmarshaller <ScheduleAction, ScheduleActionUnmarshaller>(ScheduleActionUnmarshaller.Instance); response.ScheduleActions = unmarshaller.Unmarshall(context); continue; } } return(response); }
public static DescribeScheduleResponse Unmarshall(UnmarshallerContext context) { DescribeScheduleResponse describeScheduleResponse = new DescribeScheduleResponse(); describeScheduleResponse.HttpResponse = context.HttpResponse; describeScheduleResponse.RequestId = context.StringValue("DescribeSchedule.RequestId"); describeScheduleResponse.ScheduleName = context.StringValue("DescribeSchedule.ScheduleName"); describeScheduleResponse.Description = context.StringValue("DescribeSchedule.Description"); describeScheduleResponse.ScheduleId = context.StringValue("DescribeSchedule.ScheduleId"); describeScheduleResponse.Payload = context.StringValue("DescribeSchedule.Payload"); describeScheduleResponse.CronExpression = context.StringValue("DescribeSchedule.CronExpression"); describeScheduleResponse.Enable = context.BooleanValue("DescribeSchedule.Enable"); describeScheduleResponse.CreatedTime = context.StringValue("DescribeSchedule.CreatedTime"); describeScheduleResponse.LastModifiedTime = context.StringValue("DescribeSchedule.LastModifiedTime"); return(describeScheduleResponse); }
/// <summary> /// Unmarshaller the response from the service to the response class. /// </summary> /// <param name="context"></param> /// <returns></returns> public override AmazonWebServiceResponse Unmarshall(JsonUnmarshallerContext context) { DescribeScheduleResponse response = new DescribeScheduleResponse(); context.Read(); int targetDepth = context.CurrentDepth; while (context.ReadAtDepth(targetDepth)) { if (context.TestExpression("CreateDate", targetDepth)) { var unmarshaller = DateTimeUnmarshaller.Instance; response.CreateDate = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("CreatedBy", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.CreatedBy = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("CronExpression", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.CronExpression = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("JobNames", targetDepth)) { var unmarshaller = new ListUnmarshaller <string, StringUnmarshaller>(StringUnmarshaller.Instance); response.JobNames = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("LastModifiedBy", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.LastModifiedBy = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("LastModifiedDate", targetDepth)) { var unmarshaller = DateTimeUnmarshaller.Instance; response.LastModifiedDate = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("Name", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.Name = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("ResourceArn", targetDepth)) { var unmarshaller = StringUnmarshaller.Instance; response.ResourceArn = unmarshaller.Unmarshall(context); continue; } if (context.TestExpression("Tags", targetDepth)) { var unmarshaller = new DictionaryUnmarshaller <string, string, StringUnmarshaller, StringUnmarshaller>(StringUnmarshaller.Instance, StringUnmarshaller.Instance); response.Tags = unmarshaller.Unmarshall(context); continue; } } return(response); }