pub struct KbdHandler<'d, A: UsbHostAllocator<'d>> { /* private fields */ }Expand description
Host-side HID boot-keyboard driver.
Implementations§
Source§impl<'d, A: UsbHostAllocator<'d>> KbdHandler<'d, A>
impl<'d, A: UsbHostAllocator<'d>> KbdHandler<'d, A>
Sourcepub async fn try_register(
alloc: &A,
enum_info: &EnumerationInfo,
) -> Result<Self, RegisterError>
pub async fn try_register( alloc: &A, enum_info: &EnumerationInfo, ) -> Result<Self, RegisterError>
Attempt to register a keyboard handler for the given device.
Sourcepub async fn wait_for_event(
&mut self,
) -> Result<HandlerEvent<KbdEvent>, HostError>
pub async fn wait_for_event( &mut self, ) -> Result<HandlerEvent<KbdEvent>, HostError>
Wait for the next keyboard event.
Auto Trait Implementations§
impl<'d, A> Freeze for KbdHandler<'d, A>where
<A as UsbHostAllocator<'d>>::Pipe<Interrupt, In>: Freeze,
<A as UsbHostAllocator<'d>>::Pipe<Control, InOut>: Freeze,
impl<'d, A> RefUnwindSafe for KbdHandler<'d, A>where
<A as UsbHostAllocator<'d>>::Pipe<Interrupt, In>: RefUnwindSafe,
<A as UsbHostAllocator<'d>>::Pipe<Control, InOut>: RefUnwindSafe,
impl<'d, A> Send for KbdHandler<'d, A>where
<A as UsbHostAllocator<'d>>::Pipe<Interrupt, In>: Send,
<A as UsbHostAllocator<'d>>::Pipe<Control, InOut>: Send,
impl<'d, A> Sync for KbdHandler<'d, A>where
<A as UsbHostAllocator<'d>>::Pipe<Interrupt, In>: Sync,
<A as UsbHostAllocator<'d>>::Pipe<Control, InOut>: Sync,
impl<'d, A> Unpin for KbdHandler<'d, A>where
<A as UsbHostAllocator<'d>>::Pipe<Interrupt, In>: Unpin,
<A as UsbHostAllocator<'d>>::Pipe<Control, InOut>: Unpin,
impl<'d, A> UnwindSafe for KbdHandler<'d, A>where
<A as UsbHostAllocator<'d>>::Pipe<Interrupt, In>: UnwindSafe,
<A as UsbHostAllocator<'d>>::Pipe<Control, InOut>: UnwindSafe,
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