pub struct DesignatorIndex(/* private fields */);Expand description
Determines the body part used for a control. Index points to a designator in the Physical descriptor.
Implementations§
Source§impl DesignatorIndex
impl DesignatorIndex
Sourcepub const PREFIX: u8 = 0b0011_1000
pub const PREFIX: u8 = 0b0011_1000
Prefix consists of tag(bit 7-4), type(bit 3-2) and size(bit 1-0).
The “size” part is set to 00 in this constant value.
Sourcepub unsafe fn new_unchecked(raw: &[u8]) -> Self
pub unsafe fn new_unchecked(raw: &[u8]) -> Self
Sourcepub fn new_with(data: &[u8]) -> Result<Self, HidError>
pub fn new_with(data: &[u8]) -> Result<Self, HidError>
Create an item with specific data.
NOTE: data size must be: 0, 1, 2 or 4.
Trait Implementations§
Source§impl AsRef<[u8]> for DesignatorIndex
impl AsRef<[u8]> for DesignatorIndex
Source§impl Clone for DesignatorIndex
impl Clone for DesignatorIndex
Source§fn clone(&self) -> DesignatorIndex
fn clone(&self) -> DesignatorIndex
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DesignatorIndex
impl Debug for DesignatorIndex
Source§impl Default for DesignatorIndex
impl Default for DesignatorIndex
Source§impl Display for DesignatorIndex
impl Display for DesignatorIndex
Source§impl PartialEq for DesignatorIndex
impl PartialEq for DesignatorIndex
Source§fn eq(&self, other: &DesignatorIndex) -> bool
fn eq(&self, other: &DesignatorIndex) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for DesignatorIndex
impl StructuralPartialEq for DesignatorIndex
Auto Trait Implementations§
impl Freeze for DesignatorIndex
impl RefUnwindSafe for DesignatorIndex
impl Send for DesignatorIndex
impl Sync for DesignatorIndex
impl Unpin for DesignatorIndex
impl UnsafeUnpin for DesignatorIndex
impl UnwindSafe for DesignatorIndex
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