pub struct DestinationFormat { /* private fields */ }
Expand description
Destination Format Register.
Implementations§
Source§impl DestinationFormat
impl DestinationFormat
Sourcepub const fn into_bytes(self) -> [u8; 16]
pub const fn into_bytes(self) -> [u8; 16]
Sourcepub const fn from_bytes(bytes: [u8; 16]) -> Self
pub const fn from_bytes(bytes: [u8; 16]) -> Self
Converts the given bytes directly into the bitfield struct.
Source§impl DestinationFormat
impl DestinationFormat
Sourcepub fn model_or_err(
&self,
) -> Result<<B4 as Specifier>::InOut, InvalidBitPattern<<B4 as Specifier>::Bytes>>
pub fn model_or_err( &self, ) -> Result<<B4 as Specifier>::InOut, InvalidBitPattern<<B4 as Specifier>::Bytes>>
Returns the value of model.
#Errors
If the returned value contains an invalid bit pattern for model.
Sourcepub fn with_model(self, new_val: <B4 as Specifier>::InOut) -> Self
pub fn with_model(self, new_val: <B4 as Specifier>::InOut) -> Self
Returns a copy of the bitfield with the value of model set to the given value.
#Panics
If the given value is out of bounds for model.
Sourcepub fn with_model_checked(
self,
new_val: <B4 as Specifier>::InOut,
) -> Result<Self, OutOfBounds>
pub fn with_model_checked( self, new_val: <B4 as Specifier>::InOut, ) -> Result<Self, OutOfBounds>
Returns a copy of the bitfield with the value of model set to the given value.
#Errors
If the given value is out of bounds for model.
Sourcepub fn set_model(&mut self, new_val: <B4 as Specifier>::InOut)
pub fn set_model(&mut self, new_val: <B4 as Specifier>::InOut)
Sets the value of model to the given value.
#Panics
If the given value is out of bounds for model.
Sourcepub fn set_model_checked(
&mut self,
new_val: <B4 as Specifier>::InOut,
) -> Result<(), OutOfBounds>
pub fn set_model_checked( &mut self, new_val: <B4 as Specifier>::InOut, ) -> Result<(), OutOfBounds>
Sets the value of model to the given value.
#Errors
If the given value is out of bounds for model.
Trait Implementations§
Source§impl Clone for DestinationFormat
impl Clone for DestinationFormat
Source§fn clone(&self) -> DestinationFormat
fn clone(&self) -> DestinationFormat
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 DestinationFormat
impl Debug for DestinationFormat
Source§impl Default for DestinationFormat
impl Default for DestinationFormat
Source§fn default() -> DestinationFormat
fn default() -> DestinationFormat
Returns the “default value” for a type. Read more
Source§impl PartialEq for DestinationFormat
impl PartialEq for DestinationFormat
impl Copy for DestinationFormat
impl Eq for DestinationFormat
impl StructuralPartialEq for DestinationFormat
Auto Trait Implementations§
impl Freeze for DestinationFormat
impl RefUnwindSafe for DestinationFormat
impl Send for DestinationFormat
impl Sync for DestinationFormat
impl Unpin for DestinationFormat
impl UnwindSafe for DestinationFormat
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