DictationManager class
Manages connection and audio transmission to the server
Constructors
- DictationManager(AugnitoConfig augnitoConfig, {dynamic onConnected()?, dynamic onError(DictationError)?, dynamic onDisconnected()?, dynamic onFinalResult(String transcription)?, dynamic onPartialResult(String hypothesis)?, dynamic onCommandResult(ActionRecipe actionRecipe)?, bool enableLogs = false})
- Creates a Dictation Manager object. Supports callback methods for different events:
- DictationManager.fromCustomSpeechURL(String customSpeechURL, {dynamic onConnected()?, dynamic onError(DictationError)?, dynamic onDisconnected()?, dynamic onFinalResult(String transcription)?, dynamic onPartialResult(String hypothesis)?, dynamic onCommandResult(ActionRecipe actionRecipe)?, bool enableLogs = false})
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isBusy → bool
-
no setter
- onCommandResult ↔ (dynamic Function(ActionRecipe actionRecipe)?)
-
getter/setter pair
- onConnected ↔ (dynamic Function()?)
-
called when the server sends a successful pairing message
getter/setter pair
- onDisconnected ↔ (dynamic Function()?)
-
called when the socket disconnects
getter/setter pair
- onError ↔ (dynamic Function(DictationError)?)
-
called on errors
getter/setter pair
- onFinalResult ↔ (dynamic Function(String transcription)?)
-
Final result
getter/setter pair
- onPartialResult ↔ (dynamic Function(String hypothesis)?)
-
Hypothesis result
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
dispose(
) → void - Closes the underlying streams and objects. Calls the dispose method on the native code as well.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toggleDictation(
) → Future< void> - Initializes or stops the dictation flow.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited