/** * <p> * The current status of the stream, the stream Amazon Resource Name (ARN), an array of shard objects that comprise * the stream, and whether there are more shards available. * </p> * * @param streamDescription * The current status of the stream, the stream Amazon Resource Name (ARN), an array of shard objects that * comprise the stream, and whether there are more shards available. * @return Returns a reference to this object so that method calls can be chained together. */ public DescribeStreamResult withStreamDescription(StreamDescription streamDescription) { setStreamDescription(streamDescription); return this; }
public DescribeStreamResult unmarshall(JsonUnmarshallerContext context) throws Exception { DescribeStreamResult describeStreamResult = new DescribeStreamResult(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) { return describeStreamResult; } while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("StreamDescription", targetDepth)) { context.nextToken(); describeStreamResult.setStreamDescription(StreamDescriptionJsonUnmarshaller.getInstance().unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return describeStreamResult; }
public DescribeStreamResult unmarshall(JsonUnmarshallerContext context) throws Exception { DescribeStreamResult describeStreamResult = new DescribeStreamResult(); AwsJsonReader reader = context.getReader(); reader.beginObject(); while (reader.hasNext()) { String name = reader.nextName(); if (name.equals("StreamDescription")) { describeStreamResult.setStreamDescription(StreamDescriptionJsonUnmarshaller .getInstance() .unmarshall(context)); } else { reader.skipValue(); } } reader.endObject(); return describeStreamResult; }
/** * <p> * The current status of the stream, the stream Amazon Resource Name (ARN), an array of shard objects that comprise * the stream, and whether there are more shards available. * </p> * * @param streamDescription * The current status of the stream, the stream Amazon Resource Name (ARN), an array of shard objects that * comprise the stream, and whether there are more shards available. * @return Returns a reference to this object so that method calls can be chained together. */ public DescribeStreamResult withStreamDescription(StreamDescription streamDescription) { setStreamDescription(streamDescription); return this; }
public DescribeStreamResult unmarshall(JsonUnmarshallerContext context) throws Exception { DescribeStreamResult describeStreamResult = new DescribeStreamResult(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) { return describeStreamResult; } while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("StreamDescription", targetDepth)) { context.nextToken(); describeStreamResult.setStreamDescription(StreamDescriptionJsonUnmarshaller.getInstance().unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return describeStreamResult; }