pub struct StringDescriptorZero {
pub lang_ids: Vec<u16, { _ }>,
}Expand description
String Descriptor Zero (USB 2.0 §9.6.7)
A descriptor with index 0 specifies which languages are supported by the device.
Fields§
§lang_ids: Vec<u16, { _ }>LANGID codes
Trait Implementations§
Source§impl Clone for StringDescriptorZero
impl Clone for StringDescriptorZero
Source§fn clone(&self) -> StringDescriptorZero
fn clone(&self) -> StringDescriptorZero
Returns a duplicate of the value. Read more
1.0.0 · 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 StringDescriptorZero
impl Debug for StringDescriptorZero
Source§impl Format for StringDescriptorZero
impl Format for StringDescriptorZero
Source§impl PartialEq for StringDescriptorZero
impl PartialEq for StringDescriptorZero
Source§impl USBDescriptor for StringDescriptorZero
impl USBDescriptor for StringDescriptorZero
type Error = DescriptorError
fn try_from_bytes(bytes: &[u8]) -> Result<Self, Self::Error>
Source§impl VariableSizeDescriptor for StringDescriptorZero
impl VariableSizeDescriptor for StringDescriptorZero
Source§fn match_bytes_len(bytes: &[u8]) -> bool
fn match_bytes_len(bytes: &[u8]) -> bool
Matches len with the size of a lang_id value.
Source§fn match_bytes(bytes: &[u8]) -> Result<(), DescriptorError>
fn match_bytes(bytes: &[u8]) -> Result<(), DescriptorError>
Matches
bytes with this descriptor. Read moreSource§fn prepare_bytes(bytes: &mut [u8], len: u8) -> Result<(), DescriptorError>where
Self: WritableDescriptor,
fn prepare_bytes(bytes: &mut [u8], len: u8) -> Result<(), DescriptorError>where
Self: WritableDescriptor,
Prepares
bytes to receive descriptor data. Read moreSource§impl WritableDescriptor for StringDescriptorZero
impl WritableDescriptor for StringDescriptorZero
impl Eq for StringDescriptorZero
impl StructuralPartialEq for StringDescriptorZero
Auto Trait Implementations§
impl Freeze for StringDescriptorZero
impl RefUnwindSafe for StringDescriptorZero
impl Send for StringDescriptorZero
impl Sync for StringDescriptorZero
impl Unpin for StringDescriptorZero
impl UnwindSafe for StringDescriptorZero
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