Struct usb_pd::messages::pdo::AVSRequestDataObject
source · pub struct AVSRequestDataObject(pub u32);
Tuple Fields§
§0: u32
Implementations§
source§impl AVSRequestDataObject
impl AVSRequestDataObject
sourcepub fn object_position(&self) -> u8
pub fn object_position(&self) -> u8
Object position (0000b and 1110b…1111b are Reserved and Shall Not be used)
sourcepub fn with_object_position(self, value: u8) -> Self
pub fn with_object_position(self, value: u8) -> Self
Object position (0000b and 1110b…1111b are Reserved and Shall Not be used)
sourcepub fn set_object_position(&mut self, value: u8)
pub fn set_object_position(&mut self, value: u8)
Object position (0000b and 1110b…1111b are Reserved and Shall Not be used)
sourcepub fn capability_mismatch(&self) -> bool
pub fn capability_mismatch(&self) -> bool
Capability mismatch
sourcepub fn with_capability_mismatch(self, value: bool) -> Self
pub fn with_capability_mismatch(self, value: bool) -> Self
Capability mismatch
sourcepub fn set_capability_mismatch(&mut self, value: bool)
pub fn set_capability_mismatch(&mut self, value: bool)
Capability mismatch
sourcepub fn usb_communications_capable(&self) -> bool
pub fn usb_communications_capable(&self) -> bool
USB communications capable
sourcepub fn with_usb_communications_capable(self, value: bool) -> Self
pub fn with_usb_communications_capable(self, value: bool) -> Self
USB communications capable
sourcepub fn set_usb_communications_capable(&mut self, value: bool)
pub fn set_usb_communications_capable(&mut self, value: bool)
USB communications capable
sourcepub fn no_usb_suspend(&self) -> bool
pub fn no_usb_suspend(&self) -> bool
No USB Suspend
sourcepub fn with_no_usb_suspend(self, value: bool) -> Self
pub fn with_no_usb_suspend(self, value: bool) -> Self
No USB Suspend
sourcepub fn set_no_usb_suspend(&mut self, value: bool)
pub fn set_no_usb_suspend(&mut self, value: bool)
No USB Suspend
sourcepub fn unchunked_extended_messages_supported(&self) -> bool
pub fn unchunked_extended_messages_supported(&self) -> bool
Unchunked extended messages supported
sourcepub fn with_unchunked_extended_messages_supported(self, value: bool) -> Self
pub fn with_unchunked_extended_messages_supported(self, value: bool) -> Self
Unchunked extended messages supported
sourcepub fn set_unchunked_extended_messages_supported(&mut self, value: bool)
pub fn set_unchunked_extended_messages_supported(&mut self, value: bool)
Unchunked extended messages supported
sourcepub fn epr_mode_capable(&self) -> bool
pub fn epr_mode_capable(&self) -> bool
EPR mode capable
sourcepub fn with_epr_mode_capable(self, value: bool) -> Self
pub fn with_epr_mode_capable(self, value: bool) -> Self
EPR mode capable
sourcepub fn set_epr_mode_capable(&mut self, value: bool)
pub fn set_epr_mode_capable(&mut self, value: bool)
EPR mode capable
sourcepub fn raw_output_voltage(&self) -> u16
pub fn raw_output_voltage(&self) -> u16
Output voltage in 20mV units
sourcepub fn with_raw_output_voltage(self, value: u16) -> Self
pub fn with_raw_output_voltage(self, value: u16) -> Self
Output voltage in 20mV units
sourcepub fn set_raw_output_voltage(&mut self, value: u16)
pub fn set_raw_output_voltage(&mut self, value: u16)
Output voltage in 20mV units
sourcepub fn raw_operating_current(&self) -> u16
pub fn raw_operating_current(&self) -> u16
Operating current in 50mA units
sourcepub fn with_raw_operating_current(self, value: u16) -> Self
pub fn with_raw_operating_current(self, value: u16) -> Self
Operating current in 50mA units
sourcepub fn set_raw_operating_current(&mut self, value: u16)
pub fn set_raw_operating_current(&mut self, value: u16)
Operating current in 50mA units
source§impl AVSRequestDataObject
impl AVSRequestDataObject
pub fn to_bytes(&self, buf: &mut [u8])
pub fn output_voltage(&self) -> ElectricPotential
pub fn operating_current(&self) -> ElectricCurrent
Trait Implementations§
source§impl Clone for AVSRequestDataObject
impl Clone for AVSRequestDataObject
source§fn clone(&self) -> AVSRequestDataObject
fn clone(&self) -> AVSRequestDataObject
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for AVSRequestDataObject
impl Debug for AVSRequestDataObject
source§impl Format for AVSRequestDataObject
impl Format for AVSRequestDataObject
source§impl From<AVSRequestDataObject> for u32
impl From<AVSRequestDataObject> for u32
source§fn from(other: AVSRequestDataObject) -> Self
fn from(other: AVSRequestDataObject) -> Self
source§impl From<u32> for AVSRequestDataObject
impl From<u32> for AVSRequestDataObject
source§impl PartialEq for AVSRequestDataObject
impl PartialEq for AVSRequestDataObject
source§fn eq(&self, other: &AVSRequestDataObject) -> bool
fn eq(&self, other: &AVSRequestDataObject) -> bool
self
and other
values to be equal, and is used
by ==
.impl Copy for AVSRequestDataObject
impl Eq for AVSRequestDataObject
impl StructuralPartialEq for AVSRequestDataObject
Auto Trait Implementations§
impl Freeze for AVSRequestDataObject
impl RefUnwindSafe for AVSRequestDataObject
impl Send for AVSRequestDataObject
impl Sync for AVSRequestDataObject
impl Unpin for AVSRequestDataObject
impl UnwindSafe for AVSRequestDataObject
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
source§impl<T, U> UnsafeFrom<U> for Twhere
U: Into<T>,
impl<T, U> UnsafeFrom<U> for Twhere
U: Into<T>,
source§unsafe fn unsafe_from(other: U) -> T
unsafe fn unsafe_from(other: U) -> T
Calls U::into(other)
.
That is, this conversion is whatever the implementation of Into
<T> for U
chooses to
do.
source§impl<T, U> UnsafeInto<U> for Twhere
U: UnsafeFrom<T>,
impl<T, U> UnsafeInto<U> for Twhere
U: UnsafeFrom<T>,
source§unsafe fn unsafe_into(self) -> U
unsafe fn unsafe_into(self) -> U
Calls U::unsafe_from(self)
.
That is, this conversion is whatever the implementation of UnsafeFrom
<T> for U
chooses to do.