pub trait AsyncHidRead {
// Required method
fn read_input_report<'a>(
&'a mut self,
buf: &'a mut [u8],
) -> impl Future<Output = HidResult<usize>> + Send + 'a;
}
Expand description
Provides functionality for reading from HID devices
Required Methods§
Sourcefn read_input_report<'a>(
&'a mut self,
buf: &'a mut [u8],
) -> impl Future<Output = HidResult<usize>> + Send + 'a
fn read_input_report<'a>( &'a mut self, buf: &'a mut [u8], ) -> impl Future<Output = HidResult<usize>> + Send + 'a
Read an input report from a HID device.
The submitted buffer must be big enough to contain the entire report or the report will be truncated If the device uses numbered report the first byte will contain the report id
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.