TranslatedTextItem Class
- java.
lang. Object - com.
azure. ai. translation. text. models. TranslatedTextItem
- com.
Implements
public final class TranslatedTextItem
implements JsonSerializable<TranslatedTextItem>
Element containing the translated text.
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
static
Translated |
fromJson(JsonReader jsonReader)
Reads an instance of Translated |
|
Detected |
getDetectedLanguage()
Get the detected |
|
List<Translation |
getTranslations()
Get the translations property: An array of translation results. |
|
Json |
toJson(JsonWriter jsonWriter) |
Methods inherited from java.lang.Object
Method Details
fromJson
public static TranslatedTextItem fromJson(JsonReader jsonReader)
Reads an instance of TranslatedTextItem from the JsonReader.
Parameters:
Returns:
Throws:
getDetectedLanguage
public DetectedLanguage getDetectedLanguage()
Get the detectedLanguage property: The detectedLanguage property is only present in the result object when language auto-detection is requested.
Returns:
getTranslations
public List<TranslationText> getTranslations()
Get the translations property: An array of translation results. The size of the array matches the number of target languages specified through the to query parameter.
Returns: