pub enum Exclude {
First,
Last,
None_,
Both,
}Expand description
Which nibbles are excluded from the NibSlice but are included in the internal [u8]
Variants§
First
the first (high) nibble in the slice is excluded
Last
the last (low) nibble in the slice is excluded
None_
no nibbles in the byte slice are excluded
Both
both the high nibble in the first byte and the low nibble in the last byte are excluded
Implementations§
Source§impl Exclude
impl Exclude
Sourcepub fn is_first_excluded(self) -> bool
pub fn is_first_excluded(self) -> bool
Is the first nibble (high) excluded?
Sourcepub fn is_last_excluded(self) -> bool
pub fn is_last_excluded(self) -> bool
Is the last nibble (low) excluded?
Sourcepub fn len_excluded(self) -> usize
pub fn len_excluded(self) -> usize
Number of nibbles to be excluded
Sourcepub fn from_includes(include_first: bool, include_last: bool) -> Self
pub fn from_includes(include_first: bool, include_last: bool) -> Self
Given bools of what to include, generate an Exclude instance
Sourcepub fn from_excludes(exclude_first: bool, exclude_last: bool) -> Self
pub fn from_excludes(exclude_first: bool, exclude_last: bool) -> Self
Given bools of what to exclude, generate an Exclude instance
Trait Implementations§
Source§impl Ord for Exclude
impl Ord for Exclude
Source§impl PartialOrd for Exclude
impl PartialOrd for Exclude
impl Copy for Exclude
impl Eq for Exclude
impl StructuralPartialEq for Exclude
Auto Trait Implementations§
impl Freeze for Exclude
impl RefUnwindSafe for Exclude
impl Send for Exclude
impl Sync for Exclude
impl Unpin for Exclude
impl UnwindSafe for Exclude
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