pub enum BitOrder {
Msb,
Lsb,
}Expand description
Bit packing order within a bitfield: does the first declared field occupy the most-significant or least-significant bits of the backing integer.
Most network protocols (and the ASCII-art layouts in their RFCs) are
most-significant-first, so Msb is the crate default.
§Examples
use bnb::BitOrder;
assert_eq!(BitOrder::default(), BitOrder::Msb); // first field in the high bitsVariants§
Msb
First field in the high bits (network / RFC-diagram order). The default.
Lsb
First field in the low bits.
Trait Implementations§
impl Copy for BitOrder
impl Eq for BitOrder
impl StructuralPartialEq for BitOrder
Auto Trait Implementations§
impl Freeze for BitOrder
impl RefUnwindSafe for BitOrder
impl Send for BitOrder
impl Sync for BitOrder
impl Unpin for BitOrder
impl UnsafeUnpin for BitOrder
impl UnwindSafe for BitOrder
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