Class TranslationRecognitionResult
- java.lang.Object
-
- com.microsoft.cognitiveservices.speech.RecognitionResult
-
- com.microsoft.cognitiveservices.speech.translation.TranslationRecognitionResult
-
- All Implemented Interfaces:
AutoCloseable
- Direct Known Subclasses:
ConversationTranslationResult
public class TranslationRecognitionResult extends RecognitionResult
Defines translation recognition result.
-
-
Constructor Summary
Constructors Constructor Description TranslationRecognitionResult(long result)Internal constructor for creating a TranslationRecognitionResult from a native handle.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,String>getTranslations()Presents the translation results.StringtoString()Returns a String that represents the translation recognition result.-
Methods inherited from class com.microsoft.cognitiveservices.speech.RecognitionResult
close, getDuration, getImpl, getOffset, getProperties, getReason, getResultId, getText
-
-
-
-
Constructor Detail
-
TranslationRecognitionResult
public TranslationRecognitionResult(long result)
Internal constructor for creating a TranslationRecognitionResult from a native handle.- Parameters:
result-IntentRecognitionResult
-
-
Method Detail
-
getTranslations
public final Map<String,String> getTranslations()
Presents the translation results. Each item in the dictionary represents translation result in one of target languages, where the key is the name of the target language, in BCP-47 format, and the value is the translation text in the specified language.- Returns:
- the current translation map.
-
-