Class CallMediaRecognizeSpeechOptions
java.lang.Object
com.azure.communication.callautomation.models.CallMediaRecognizeOptions
com.azure.communication.callautomation.models.CallMediaRecognizeSpeechOptions
- All Implemented Interfaces:
com.azure.json.JsonSerializable<CallMediaRecognizeOptions>
The Recognize configurations specific for Continuous Speech Recognition.
-
Constructor Summary
ConstructorsConstructorDescriptionCallMediaRecognizeSpeechOptions(CommunicationIdentifier targetParticipant, Duration endSilenceTimeout) Initializes a CallMediaRecognizeSpeechOptions object. -
Method Summary
Modifier and TypeMethodDescriptionfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of CallMediaRecognizeSpeechOptions from the JsonReader.Get the endSilenceTimeout property: The length of end silence when user stops speaking and cogservice send response.Get the speech language property.Get the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.setInitialSilenceTimeout(Duration initialSilenceTimeout) Set the initialSilenceTimeout property: Time to wait for first input after prompt (if any).setInterruptCallMediaOperation(Boolean interruptCallMediaOperation) Set the interruptCallMediaOperation property: If set recognize can barge into other existing queued-up/currently-processing requests.setInterruptPrompt(Boolean interruptPrompt) Set the interruptPrompt property: Determines if we interrupt the prompt and start recognizing.setOperationContext(String operationContext) Set the operationContext property: The value to identify context of the operation.setPlayPrompt(PlaySource playPrompt) Set the playPrompt property: The source of the audio to be played for recognition.setRecognizeInputType(RecognizeInputType recognizeInputType) Set the recognizeInputType property: Determines the type of the recognition.setSpeechLanguage(String speechLanguage) Set the speech language property.setSpeechRecognitionModelEndpointId(String speechRecognitionModelEndpointId) Set the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.setStopCurrentOperations(Boolean stopCurrentOperations) Set the stopCurrentOperations property: If set recognize can barge into other existing queued-up/currently-processing requests.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) Methods inherited from class com.azure.communication.callautomation.models.CallMediaRecognizeOptions
getInitialSilenceTimeout, getOperationCallbackUrl, getOperationContext, getPlayPrompt, getPlayPrompts, getRecognizeInputType, getTargetParticipant, isInterruptCallMediaOperation, isInterruptPrompt, isStopCurrentOperations, setOperationCallbackUrl, setPlayPrompts, setPlayPromptsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
CallMediaRecognizeSpeechOptions
public CallMediaRecognizeSpeechOptions(CommunicationIdentifier targetParticipant, Duration endSilenceTimeout) Initializes a CallMediaRecognizeSpeechOptions object.- Parameters:
targetParticipant- Target participant of continuous speech recognition.endSilenceTimeout- the endSilenceTimeout value to set.
-
-
Method Details
-
getEndSilenceTimeout
Get the endSilenceTimeout property: The length of end silence when user stops speaking and cogservice send response.- Returns:
- the endSilenceTimeout value.
-
setRecognizeInputType
Set the recognizeInputType property: Determines the type of the recognition.- Overrides:
setRecognizeInputTypein classCallMediaRecognizeOptions- Parameters:
recognizeInputType- the recognizeInputType value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setPlayPrompt
Set the playPrompt property: The source of the audio to be played for recognition.- Overrides:
setPlayPromptin classCallMediaRecognizeOptions- Parameters:
playPrompt- the playPrompt value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setInterruptCallMediaOperation
public CallMediaRecognizeSpeechOptions setInterruptCallMediaOperation(Boolean interruptCallMediaOperation) Set the interruptCallMediaOperation property: If set recognize can barge into other existing queued-up/currently-processing requests.- Overrides:
setInterruptCallMediaOperationin classCallMediaRecognizeOptions- Parameters:
interruptCallMediaOperation- the interruptCallMediaOperation value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setStopCurrentOperations
Set the stopCurrentOperations property: If set recognize can barge into other existing queued-up/currently-processing requests.- Overrides:
setStopCurrentOperationsin classCallMediaRecognizeOptions- Parameters:
stopCurrentOperations- the stopCurrentOperations value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setOperationContext
Set the operationContext property: The value to identify context of the operation.- Overrides:
setOperationContextin classCallMediaRecognizeOptions- Parameters:
operationContext- the operationContext value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setInterruptPrompt
Set the interruptPrompt property: Determines if we interrupt the prompt and start recognizing.- Overrides:
setInterruptPromptin classCallMediaRecognizeOptions- Parameters:
interruptPrompt- the interruptPrompt value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setInitialSilenceTimeout
Set the initialSilenceTimeout property: Time to wait for first input after prompt (if any).- Overrides:
setInitialSilenceTimeoutin classCallMediaRecognizeOptions- Parameters:
initialSilenceTimeout- the initialSilenceTimeout value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
setSpeechLanguage
Set the speech language property.- Parameters:
speechLanguage- the speechLanguage value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
getSpeechLanguage
Get the speech language property.- Returns:
- the speech language.
-
getSpeechRecognitionModelEndpointId
Get the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.- Returns:
- the speechRecognitionModelEndpointId value.
-
setSpeechRecognitionModelEndpointId
public CallMediaRecognizeSpeechOptions setSpeechRecognitionModelEndpointId(String speechRecognitionModelEndpointId) Set the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.- Parameters:
speechRecognitionModelEndpointId- the speechRecognitionModelEndpointId value to set.- Returns:
- the CallMediaRecognizeSpeechOptions object itself.
-
toJson
- Throws:
IOException
-
fromJson
public static CallMediaRecognizeSpeechOptions fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of CallMediaRecognizeSpeechOptions from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of CallMediaRecognizeSpeechOptions if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException- If an error occurs while reading the CallMediaRecognizeSpeechOptions.
-