pub struct TextDecoder<W> { /* private fields */ }Expand description
Decode an HID report descriptor to plain text.
Implementations§
Source§impl<W> TextDecoder<W>where
W: Write,
impl<W> TextDecoder<W>where
W: Write,
Sourcepub fn new(writer: W) -> Self
pub fn new(writer: W) -> Self
Create a new TextDecoder, by specifying where the output will be written.
§Example
let mut decoder = TextDecoder::new(std::io::stdout());Sourcepub fn display_tag_type(self) -> Self
pub fn display_tag_type(self) -> Self
Display the item tag types, i.e. Main, Global, Local.
Sourcepub fn display_raw_bytes(self) -> Self
pub fn display_raw_bytes(self) -> Self
Display the raw bytes that make up each item.
Sourcepub fn reject_zero_length_values(self) -> Self
pub fn reject_zero_length_values(self) -> Self
Don’t allow zero-length data on descriptor items with values.
Trait Implementations§
Auto Trait Implementations§
impl<W> Freeze for TextDecoder<W>where
W: Freeze,
impl<W> RefUnwindSafe for TextDecoder<W>where
W: RefUnwindSafe,
impl<W> Send for TextDecoder<W>where
W: Send,
impl<W> Sync for TextDecoder<W>where
W: Sync,
impl<W> Unpin for TextDecoder<W>where
W: Unpin,
impl<W> UnsafeUnpin for TextDecoder<W>where
W: UnsafeUnpin,
impl<W> UnwindSafe for TextDecoder<W>where
W: 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