pub enum DataPhase<'a> {
In(&'a mut [u8]),
Out(&'a [u8]),
None,
}Expand description
The data phase of a USB control-endpoint transaction
A transaction on a control endpoint involves one of:
- IN (data transferred from device to host)
- OUT (data transferred from host to device)
- neither (the Setup packet contains all the relevant data)
See USB 2.0 section 8.5.3 and fiture 8-37.
Variants§
In(&'a mut [u8])
IN transaction (device-to-host)
Out(&'a [u8])
OUT transaction (host-to-device)
None
No data phase in control transaction
Implementations§
Trait Implementations§
impl<'a> Eq for DataPhase<'a>
impl<'a> StructuralPartialEq for DataPhase<'a>
Auto Trait Implementations§
impl<'a> Freeze for DataPhase<'a>
impl<'a> RefUnwindSafe for DataPhase<'a>
impl<'a> Send for DataPhase<'a>
impl<'a> Sync for DataPhase<'a>
impl<'a> Unpin for DataPhase<'a>
impl<'a> UnsafeUnpin for DataPhase<'a>
impl<'a> !UnwindSafe for DataPhase<'a>
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