pub struct Flags(/* private fields */);
Implementations§
Source§impl Flags
impl Flags
Sourcepub const EXTENDED_LENGTH_BIT_MASK: u8 = 128u8
pub const EXTENDED_LENGTH_BIT_MASK: u8 = 128u8
If bit 8 is set, the length is extended by an extra byte.
Sourcepub const INCLUDES_VECTOR_BIT_MASK: u8 = 64u8
pub const INCLUDES_VECTOR_BIT_MASK: u8 = 64u8
If bit 7 is set, the pdu contains a vector segment
Sourcepub const INCLUDES_HEADER_BIT_MASK: u8 = 32u8
pub const INCLUDES_HEADER_BIT_MASK: u8 = 32u8
If bit 6 is set, the pdu contains a header segment
Sourcepub const INCLUDES_DATA_BIT_MASK: u8 = 16u8
pub const INCLUDES_DATA_BIT_MASK: u8 = 16u8
If bit 5 is set, the pdu contains a data segment
pub const ALL_BIT_MASK: u8 = 240u8
pub const EXTENDED_LENGTH: Self
pub const INCLUDES_VECTOR: Self
pub const INCLUDES_HEADER: Self
pub const INCLUDES_DATA: Self
pub const ALL: Self
pub const fn new(flags: u8) -> Self
pub const fn empty() -> Self
pub const fn bits(&self) -> u8
pub const fn is_extended_length(&self) -> bool
pub const fn is_includes_vector(&self) -> bool
pub const fn is_includes_header(&self) -> bool
pub const fn is_includes_data(&self) -> bool
pub const fn is_all(&self) -> bool
pub fn encode(&self, buf: &mut [u8]) -> Result<usize, AcnError>
pub fn decode(buf: &[u8]) -> Result<Self, AcnError>
Trait Implementations§
Source§impl BitAndAssign<Flags> for u8
impl BitAndAssign<Flags> for u8
Source§fn bitand_assign(&mut self, rhs: Flags)
fn bitand_assign(&mut self, rhs: Flags)
Performs the
&=
operation. Read moreSource§impl BitAndAssign<u8> for Flags
impl BitAndAssign<u8> for Flags
Source§fn bitand_assign(&mut self, rhs: u8)
fn bitand_assign(&mut self, rhs: u8)
Performs the
&=
operation. Read moreSource§impl BitAndAssign for Flags
impl BitAndAssign for Flags
Source§fn bitand_assign(&mut self, rhs: Self)
fn bitand_assign(&mut self, rhs: Self)
Performs the
&=
operation. Read moreSource§impl BitOrAssign<Flags> for u8
impl BitOrAssign<Flags> for u8
Source§fn bitor_assign(&mut self, rhs: Flags)
fn bitor_assign(&mut self, rhs: Flags)
Performs the
|=
operation. Read moreSource§impl BitOrAssign<u8> for Flags
impl BitOrAssign<u8> for Flags
Source§fn bitor_assign(&mut self, rhs: u8)
fn bitor_assign(&mut self, rhs: u8)
Performs the
|=
operation. Read moreSource§impl BitOrAssign for Flags
impl BitOrAssign for Flags
Source§fn bitor_assign(&mut self, rhs: Self)
fn bitor_assign(&mut self, rhs: Self)
Performs the
|=
operation. Read moreimpl Copy for Flags
impl StructuralPartialEq for Flags
Auto Trait Implementations§
impl Freeze for Flags
impl RefUnwindSafe for Flags
impl Send for Flags
impl Sync for Flags
impl Unpin for Flags
impl UnwindSafe for Flags
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