Class RecognitionEventArgs
- java.lang.Object
-
- com.microsoft.cognitiveservices.speech.SessionEventArgs
-
- com.microsoft.cognitiveservices.speech.RecognitionEventArgs
-
- Direct Known Subclasses:
ConversationTranscriptionEventArgs,ConversationTranslationEventArgs,IntentRecognitionEventArgs,KeywordRecognitionEventArgs,MeetingTranscriptionEventArgs,SpeechRecognitionEventArgs,TranslationRecognitionEventArgs
public class RecognitionEventArgs extends SessionEventArgs
Defines payload for recognition events like Speech Start/End Detected
-
-
Field Summary
Fields Modifier and Type Field Description BigIntegeroffsetRepresents the message offset in 100nsec increments.-
Fields inherited from class com.microsoft.cognitiveservices.speech.SessionEventArgs
eventHandle
-
-
Constructor Summary
Constructors Constructor Description RecognitionEventArgs(long eventArgs)Constructs an instance of a RecognitionEventArgs object.RecognitionEventArgs(long eventArgs, boolean dispose)Constructs an instance of a RecognitionEventArgs object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected longgetRecognitionResult(SafeHandle eventHandle, IntRef resultHandle)Native JNI call to get the native handle to recognition result.StringtoString()Returns a String that represents the recognition event payload.-
Methods inherited from class com.microsoft.cognitiveservices.speech.SessionEventArgs
close, getSessionId
-
-
-
-
Field Detail
-
offset
public BigInteger offset
Represents the message offset in 100nsec increments.
-
-
Constructor Detail
-
RecognitionEventArgs
public RecognitionEventArgs(long eventArgs)
Constructs an instance of a RecognitionEventArgs object.- Parameters:
eventArgs- recognition event args object.
-
RecognitionEventArgs
public RecognitionEventArgs(long eventArgs, boolean dispose)Constructs an instance of a RecognitionEventArgs object.- Parameters:
eventArgs- recognition event args object.dispose- should the args be disposed when done?
-
-
Method Detail
-
toString
public String toString()
Returns a String that represents the recognition event payload.- Overrides:
toStringin classSessionEventArgs- Returns:
- A String that represents the recognition event payload.
-
getRecognitionResult
protected final long getRecognitionResult(SafeHandle eventHandle, IntRef resultHandle)
Native JNI call to get the native handle to recognition result.- Parameters:
eventHandle- The event handle.resultHandle- The result handle.- Returns:
- The native handle to recognition result.
-
-