use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class GetParametersForImportResultJsonUnmarshaller method unmarshall.
public GetParametersForImportResult unmarshall(JsonUnmarshallerContext context) throws Exception {
GetParametersForImportResult getParametersForImportResult = new GetParametersForImportResult();
AwsJsonReader reader = context.getReader();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("KeyId")) {
getParametersForImportResult.setKeyId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("ImportToken")) {
getParametersForImportResult.setImportToken(ByteBufferJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("PublicKey")) {
getParametersForImportResult.setPublicKey(ByteBufferJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("ParametersValidTo")) {
getParametersForImportResult.setParametersValidTo(DateJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return getParametersForImportResult;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class GrantListEntryJsonUnmarshaller method unmarshall.
public GrantListEntry unmarshall(JsonUnmarshallerContext context) throws Exception {
AwsJsonReader reader = context.getReader();
if (!reader.isContainer()) {
reader.skipValue();
return null;
}
GrantListEntry grantListEntry = new GrantListEntry();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("KeyId")) {
grantListEntry.setKeyId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("GrantId")) {
grantListEntry.setGrantId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("Name")) {
grantListEntry.setName(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("CreationDate")) {
grantListEntry.setCreationDate(DateJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("GranteePrincipal")) {
grantListEntry.setGranteePrincipal(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("RetiringPrincipal")) {
grantListEntry.setRetiringPrincipal(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("IssuingAccount")) {
grantListEntry.setIssuingAccount(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("Operations")) {
grantListEntry.setOperations(new ListUnmarshaller<String>(StringJsonUnmarshaller.getInstance()).unmarshall(context));
} else if (name.equals("Constraints")) {
grantListEntry.setConstraints(GrantConstraintsJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return grantListEntry;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class VerifyResultJsonUnmarshaller method unmarshall.
public VerifyResult unmarshall(JsonUnmarshallerContext context) throws Exception {
VerifyResult verifyResult = new VerifyResult();
AwsJsonReader reader = context.getReader();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("KeyId")) {
verifyResult.setKeyId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("SignatureValid")) {
verifyResult.setSignatureValid(BooleanJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("SigningAlgorithm")) {
verifyResult.setSigningAlgorithm(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return verifyResult;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class PredictedIntentJsonUnmarshaller method unmarshall.
public PredictedIntent unmarshall(JsonUnmarshallerContext context) throws Exception {
AwsJsonReader reader = context.getReader();
if (!reader.isContainer()) {
reader.skipValue();
return null;
}
PredictedIntent predictedIntent = new PredictedIntent();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("intentName")) {
predictedIntent.setIntentName(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("nluIntentConfidence")) {
predictedIntent.setNluIntentConfidence(IntentConfidenceJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("slots")) {
predictedIntent.setSlots(new MapUnmarshaller<String>(StringJsonUnmarshaller.getInstance()).unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return predictedIntent;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class DeleteSessionResultJsonUnmarshaller method unmarshall.
public DeleteSessionResult unmarshall(JsonUnmarshallerContext context) throws Exception {
DeleteSessionResult deleteSessionResult = new DeleteSessionResult();
AwsJsonReader reader = context.getReader();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("botName")) {
deleteSessionResult.setBotName(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("botAlias")) {
deleteSessionResult.setBotAlias(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("userId")) {
deleteSessionResult.setUserId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("sessionId")) {
deleteSessionResult.setSessionId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return deleteSessionResult;
}
Aggregations