pub struct InputSwitcher { /* private fields */ }Expand description
A !Send + !Sync native input-switcher owner.
Native deletion occurs before destruction of its report, handler, and endpoint leases because the native field is declared first. Drop stops and waits for active work before the typed native owner is deleted.
Implementations§
Source§impl InputSwitcher
impl InputSwitcher
Sourcepub fn report(&self) -> &Rc<Report>
pub fn report(&self) -> &Rc<Report>
Returns the report retained for the switcher’s native lifetime.
Sourcepub fn start(&mut self, config: &InputSwitcherConfig) -> Result<()>
pub fn start(&mut self, config: &InputSwitcherConfig) -> Result<()>
Starts the switcher.
Sourcepub fn wait_for_termination(&mut self) -> Result<()>
pub fn wait_for_termination(&mut self) -> Result<()>
Waits until native switching has stopped.
Sourcepub fn take_memory_error(&self) -> Option<CallbackError>
pub fn take_memory_error(&self) -> Option<CallbackError>
Takes the latest callback failure from a bound endpoint.
Trait Implementations§
Source§impl Drop for InputSwitcher
impl Drop for InputSwitcher
Auto Trait Implementations§
impl !RefUnwindSafe for InputSwitcher
impl !Send for InputSwitcher
impl !Sync for InputSwitcher
impl !UnwindSafe for InputSwitcher
impl Freeze for InputSwitcher
impl Unpin for InputSwitcher
impl UnsafeUnpin for InputSwitcher
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