public override AmazonWebServiceResponse Unmarshall(XmlUnmarshallerContext context)
{
GetConsoleOutputResponse response = new GetConsoleOutputResponse();
int originalDepth = context.CurrentDepth;
int targetDepth = originalDepth + 1;
if (context.IsStartOfDocument)
targetDepth = 2;
while (context.ReadAtDepth(originalDepth))
{
if (context.IsStartElement || context.IsAttribute)
{
if (context.TestExpression("instanceId", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.InstanceId = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("output", targetDepth))
{
var unmarshaller = StringUnmarshaller.Instance;
response.Output = unmarshaller.Unmarshall(context);
continue;
}
if (context.TestExpression("timestamp", targetDepth))
{
var unmarshaller = DateTimeUnmarshaller.Instance;
response.Timestamp = unmarshaller.Unmarshall(context);
continue;
}
}
}
return response;
}