Class CallMediaRecognizeSpeechOrDtmfOptions
java.lang.Object
com.azure.communication.callautomation.models.CallMediaRecognizeOptions
com.azure.communication.callautomation.models.CallMediaRecognizeSpeechOrDtmfOptions
- All Implemented Interfaces:
com.azure.json.JsonSerializable<CallMediaRecognizeOptions>
The Recognize configurations specific for Continuous Speech or DTMF Recognition.
-
Constructor Summary
ConstructorsConstructorDescriptionCallMediaRecognizeSpeechOrDtmfOptions(CommunicationIdentifier targetParticipant, int maxTonesToCollect, Duration endSilenceTimeout) Initializes a CallMediaRecognizeSpeechOrDtmfOptions object. -
Method Summary
Modifier and TypeMethodDescriptionfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of CallMediaRecognizeSpeechOrDtmfOptions from the JsonReader.Get the endSilenceTimeout property: The length of end silence when user stops speaking and cogservice send response.Get the interToneTimeout property: Time to wait between DTMF inputs to stop recognizing.intGet the maxTonesToCollect property: Maximum number of DTMFs to be collected.Get the speech language property.Get the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.Get the stopTones property: List of tones that will stop recognizing.setInterToneTimeout(Duration interToneTimeout) Set the interToneTimeout property: Time to wait between DTMF inputs to stop recognizing.setSpeechLanguage(String speechLanguage) Set the speech language property.setSpeechRecognitionModelEndpointId(String speechRecognitionModelEndpointId) Set the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.setStopTones(List<DtmfTone> stopDtmfTones) Set the stopTones property: List of tones that will stop recognizing.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, setInitialSilenceTimeout, setInterruptCallMediaOperation, setInterruptPrompt, setOperationCallbackUrl, setOperationContext, setPlayPrompt, setPlayPrompts, setPlayPrompts, setRecognizeInputType, setStopCurrentOperationsMethods 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
-
CallMediaRecognizeSpeechOrDtmfOptions
public CallMediaRecognizeSpeechOrDtmfOptions(CommunicationIdentifier targetParticipant, int maxTonesToCollect, Duration endSilenceTimeout) Initializes a CallMediaRecognizeSpeechOrDtmfOptions object.- Parameters:
targetParticipant- Target participant of continuous speech recognition.maxTonesToCollect- Maximum number of DTMF tones to be collected.endSilenceTimeout- the endSilenceTimeout value to set.
-
-
Method Details
-
getInterToneTimeout
Get the interToneTimeout property: Time to wait between DTMF inputs to stop recognizing. If left unspecified, the default value is set to 2 seconds.- Returns:
- the interToneTimeout value.
-
setInterToneTimeout
Set the interToneTimeout property: Time to wait between DTMF inputs to stop recognizing.- Parameters:
interToneTimeout- the interToneTimeout value to set.- Returns:
- the DtmfConfigurationsInternal object itself.
-
getMaxTonesToCollect
public int getMaxTonesToCollect()Get the maxTonesToCollect property: Maximum number of DTMFs to be collected.- Returns:
- the maxTonesToCollect value.
-
getStopTones
Get the stopTones property: List of tones that will stop recognizing.- Returns:
- the stopTones value.
-
setStopTones
Set the stopTones property: List of tones that will stop recognizing.- Parameters:
stopDtmfTones- the stopTones value to set.- Returns:
- the DtmfConfigurationsInternal object itself.
-
getEndSilenceTimeout
Get the endSilenceTimeout property: The length of end silence when user stops speaking and cogservice send response.- Returns:
- the endSilenceTimeout value.
-
setSpeechLanguage
Set the speech language property.- Parameters:
speechLanguage- the speechLanguage value to set.- Returns:
- the CallMediaRecognizeSpeechOrDtmfOptions 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 CallMediaRecognizeSpeechOrDtmfOptions setSpeechRecognitionModelEndpointId(String speechRecognitionModelEndpointId) Set the speechRecognitionModelEndpointId property: Endpoint where the custom model was deployed.- Parameters:
speechRecognitionModelEndpointId- the speechRecognitionModelEndpointId value to set.- Returns:
- the CallMediaRecognizeSpeechOrDtmfOptions object itself.
-
toJson
- Throws:
IOException
-
fromJson
public static CallMediaRecognizeSpeechOrDtmfOptions fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of CallMediaRecognizeSpeechOrDtmfOptions from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of CallMediaRecognizeSpeechOrDtmfOptions 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 CallMediaRecognizeSpeechOrDtmfOptions.
-