Class MeetingTranscriber
- java.lang.Object
-
- com.microsoft.cognitiveservices.speech.Recognizer
-
- com.microsoft.cognitiveservices.speech.transcription.MeetingTranscriber
-
- All Implemented Interfaces:
AutoCloseable
public final class MeetingTranscriber extends Recognizer
Performs meeting transcribing for audio input streams, and gets transcribed text and user id as a result. Note: close() must be called in order to release underlying resources held by the object.
-
-
Field Summary
Fields Modifier and Type Field Description EventHandlerImpl<MeetingTranscriptionCanceledEventArgs>canceledThe event canceled signals that the recognition was canceled.EventHandlerImpl<MeetingTranscriptionEventArgs>transcribedThe event transcribed signals that a final recognition result is received.EventHandlerImpl<MeetingTranscriptionEventArgs>transcribingThe event transcribing signals that an intermediate recognition result is received.-
Fields inherited from class com.microsoft.cognitiveservices.speech.Recognizer
disposed, eventCounter, sessionStarted, sessionStopped, speechEndDetected, speechStartDetected
-
-
Constructor Summary
Constructors Constructor Description MeetingTranscriber()Initializes a new instance of Meeting Transcriber.MeetingTranscriber(AudioConfig audioConfig)Initializes a new instance of Meeting Transcriber.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddispose(boolean disposing)This method performs cleanup of resources.OutputFormatgetOutputFormat()Gets the output format of recognition.PropertyCollectiongetProperties()The collection of properties and their values defined for this MeetingTranscriber.StringgetSpeechRecognitionLanguage()Gets the spoken language of recognition.Future<Void>joinMeetingAsync(Meeting meeting)Join a meeting.Future<Void>leaveMeetingAsync()Leave a meeting.Future<Void>startTranscribingAsync()Starts meeting transcribing on a continuous audio stream, until stopTranscribingAsync() is called.Future<Void>stopTranscribingAsync()Stops meeting transcribing.-
Methods inherited from class com.microsoft.cognitiveservices.speech.Recognizer
canceledSetCallback, close, doAsyncRecognitionAction, getImpl, getPropertyBagFromRecognizerHandle, recognize, recognizedSetCallback, recognizingSetCallback, sessionStartedEventCallback, sessionStartedSetCallback, sessionStoppedEventCallback, sessionStoppedSetCallback, speechEndDetectedEventCallback, speechEndDetectedSetCallback, speechStartDetectedEventCallback, speechStartDetectedSetCallback, startContinuousRecognition, startKeywordRecognition, stopContinuousRecognition, stopKeywordRecognition
-
-
-
-
Field Detail
-
transcribing
public final EventHandlerImpl<MeetingTranscriptionEventArgs> transcribing
The event transcribing signals that an intermediate recognition result is received.
-
transcribed
public final EventHandlerImpl<MeetingTranscriptionEventArgs> transcribed
The event transcribed signals that a final recognition result is received.
-
canceled
public final EventHandlerImpl<MeetingTranscriptionCanceledEventArgs> canceled
The event canceled signals that the recognition was canceled.
-
-
Constructor Detail
-
MeetingTranscriber
public MeetingTranscriber()
Initializes a new instance of Meeting Transcriber.
-
MeetingTranscriber
public MeetingTranscriber(AudioConfig audioConfig)
Initializes a new instance of Meeting Transcriber.- Parameters:
audioConfig- audio configuration.
-
-
Method Detail
-
getSpeechRecognitionLanguage
public String getSpeechRecognitionLanguage()
Gets the spoken language of recognition.- Returns:
- The spoken language of recognition.
-
getOutputFormat
public OutputFormat getOutputFormat()
Gets the output format of recognition.- Returns:
- The output format of recognition.
-
getProperties
public PropertyCollection getProperties()
The collection of properties and their values defined for this MeetingTranscriber.- Returns:
- The collection of properties and their values defined for this MeetingTranscriber.
-
joinMeetingAsync
public Future<Void> joinMeetingAsync(Meeting meeting)
Join a meeting. A meeting transcriber must join a meeting before transcribing audio.- Parameters:
meeting- the meeting to be joined.- Returns:
- A task representing the asynchronous operation that joins a meeting.
-
leaveMeetingAsync
public Future<Void> leaveMeetingAsync()
Leave a meeting. After leaving a meeting, no transcribing and transcribed events will be sent out.- Returns:
- A task representing the asynchronous operation that leaves a meeting.
-
startTranscribingAsync
public Future<Void> startTranscribingAsync()
Starts meeting transcribing on a continuous audio stream, until stopTranscribingAsync() is called. User must subscribe to events to receive transcription results.- Returns:
- A task representing the asynchronous operation that starts the transcription.
-
stopTranscribingAsync
public Future<Void> stopTranscribingAsync()
Stops meeting transcribing.- Returns:
- A task representing the asynchronous operation that stops the transcription.
-
dispose
protected void dispose(boolean disposing)
Description copied from class:RecognizerThis method performs cleanup of resources. The Boolean parameter disposing indicates whether the method is called from Dispose (if disposing is true) or from the finalizer (if disposing is false). Derived classes should override this method to dispose resource if needed.- Overrides:
disposein classRecognizer- Parameters:
disposing- Flag to request disposal.
-
-