public PersonDetail unmarshall(JsonUnmarshallerContext context) throws Exception { PersonDetail personDetail = new PersonDetail();
public PersonDetail unmarshall(JsonUnmarshallerContext context) throws Exception { AwsJsonReader reader = context.getReader(); if (!reader.isContainer()) { reader.skipValue(); return null; } PersonDetail personDetail = new PersonDetail(); reader.beginObject(); while (reader.hasNext()) { String name = reader.nextName(); if (name.equals("Index")) { personDetail.setIndex(LongJsonUnmarshaller.getInstance() .unmarshall(context)); } else if (name.equals("BoundingBox")) { personDetail.setBoundingBox(BoundingBoxJsonUnmarshaller.getInstance() .unmarshall(context)); } else if (name.equals("Face")) { personDetail.setFace(FaceDetailJsonUnmarshaller.getInstance() .unmarshall(context)); } else { reader.skipValue(); } } reader.endObject(); return personDetail; }