pub struct Recognizer { /* private fields */ }
Expand description
The in-process speech recognition engine.
Implementations§
Source§impl Recognizer
impl Recognizer
Sourcepub fn new() -> Result<Self>
pub fn new() -> Result<Self>
Creates a new recognition engine, configured to listen to the default recording device.
Sourcepub fn set_input(
&self,
input: RecognitionInput,
allow_fmt_changes: bool,
) -> Result<()>
pub fn set_input( &self, input: RecognitionInput, allow_fmt_changes: bool, ) -> Result<()>
Configures the recognizer to listen to the given input.
Sourcepub fn set_enabled(&self, enabled: bool) -> Result<()>
pub fn set_enabled(&self, enabled: bool) -> Result<()>
Enables or disables recognition.
Auto Trait Implementations§
impl !Freeze for Recognizer
impl RefUnwindSafe for Recognizer
impl Send for Recognizer
impl Sync for Recognizer
impl Unpin for Recognizer
impl UnwindSafe for Recognizer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more