use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class TranscriptionJobSummaryJsonUnmarshaller method unmarshall.
public TranscriptionJobSummary unmarshall(JsonUnmarshallerContext context) throws Exception {
AwsJsonReader reader = context.getReader();
if (!reader.isContainer()) {
reader.skipValue();
return null;
}
TranscriptionJobSummary transcriptionJobSummary = new TranscriptionJobSummary();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("TranscriptionJobName")) {
transcriptionJobSummary.setTranscriptionJobName(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("CreationTime")) {
transcriptionJobSummary.setCreationTime(DateJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("StartTime")) {
transcriptionJobSummary.setStartTime(DateJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("CompletionTime")) {
transcriptionJobSummary.setCompletionTime(DateJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("LanguageCode")) {
transcriptionJobSummary.setLanguageCode(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("TranscriptionJobStatus")) {
transcriptionJobSummary.setTranscriptionJobStatus(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("FailureReason")) {
transcriptionJobSummary.setFailureReason(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("OutputLocationType")) {
transcriptionJobSummary.setOutputLocationType(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("ContentRedaction")) {
transcriptionJobSummary.setContentRedaction(ContentRedactionJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("ModelSettings")) {
transcriptionJobSummary.setModelSettings(ModelSettingsJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("IdentifyLanguage")) {
transcriptionJobSummary.setIdentifyLanguage(BooleanJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("IdentifyMultipleLanguages")) {
transcriptionJobSummary.setIdentifyMultipleLanguages(BooleanJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("IdentifiedLanguageScore")) {
transcriptionJobSummary.setIdentifiedLanguageScore(FloatJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("LanguageCodes")) {
transcriptionJobSummary.setLanguageCodes(new ListUnmarshaller<LanguageCodeItem>(LanguageCodeItemJsonUnmarshaller.getInstance()).unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return transcriptionJobSummary;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class StopTextTranslationJobResultJsonUnmarshaller method unmarshall.
public StopTextTranslationJobResult unmarshall(JsonUnmarshallerContext context) throws Exception {
StopTextTranslationJobResult stopTextTranslationJobResult = new StopTextTranslationJobResult();
AwsJsonReader reader = context.getReader();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("JobId")) {
stopTextTranslationJobResult.setJobId(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("JobStatus")) {
stopTextTranslationJobResult.setJobStatus(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return stopTextTranslationJobResult;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class TermJsonUnmarshaller method unmarshall.
public Term unmarshall(JsonUnmarshallerContext context) throws Exception {
AwsJsonReader reader = context.getReader();
if (!reader.isContainer()) {
reader.skipValue();
return null;
}
Term term = new Term();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("SourceText")) {
term.setSourceText(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("TargetText")) {
term.setTargetText(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return term;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class TerminologyDataLocationJsonUnmarshaller method unmarshall.
public TerminologyDataLocation unmarshall(JsonUnmarshallerContext context) throws Exception {
AwsJsonReader reader = context.getReader();
if (!reader.isContainer()) {
reader.skipValue();
return null;
}
TerminologyDataLocation terminologyDataLocation = new TerminologyDataLocation();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("RepositoryType")) {
terminologyDataLocation.setRepositoryType(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("Location")) {
terminologyDataLocation.setLocation(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return terminologyDataLocation;
}
use of com.amazonaws.util.json.AwsJsonReader in project aws-sdk-android by aws-amplify.
the class VocabularyInfoJsonUnmarshaller method unmarshall.
public VocabularyInfo unmarshall(JsonUnmarshallerContext context) throws Exception {
AwsJsonReader reader = context.getReader();
if (!reader.isContainer()) {
reader.skipValue();
return null;
}
VocabularyInfo vocabularyInfo = new VocabularyInfo();
reader.beginObject();
while (reader.hasNext()) {
String name = reader.nextName();
if (name.equals("VocabularyName")) {
vocabularyInfo.setVocabularyName(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("LanguageCode")) {
vocabularyInfo.setLanguageCode(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("LastModifiedTime")) {
vocabularyInfo.setLastModifiedTime(DateJsonUnmarshaller.getInstance().unmarshall(context));
} else if (name.equals("VocabularyState")) {
vocabularyInfo.setVocabularyState(StringJsonUnmarshaller.getInstance().unmarshall(context));
} else {
reader.skipValue();
}
}
reader.endObject();
return vocabularyInfo;
}
Aggregations