Trait nibble::slice::NibSliceExt
[−]
[src]
pub trait NibSliceExt: Sealed { fn nibble_pairs(&self) -> NibblePairs { ... } fn nibbles(&self) -> Nibbles { ... } fn decompose(&self) -> (Option<&u4lo>, &[u4x2], Option<&u4hi>) { ... } fn get(&self, idx: usize) -> &u4 { ... } fn len(&self) -> usize { ... } fn is_empty(&self) -> bool { ... } fn into_generic(&self) -> NibSlice { ... } fn is_aligned(&self) -> bool { ... } fn is_even(&self) -> bool { ... } fn is_odd(&self) -> bool { ... } }
A slice of nibbles.
Provided Methods
fn nibble_pairs(&self) -> NibblePairs
Iterator over the nibble pairs in this slice.
This may include nibbles that are omitted.
fn nibbles(&self) -> Nibbles
Iterator over nibbles in a slice.
fn decompose(&self) -> (Option<&u4lo>, &[u4x2], Option<&u4hi>)
Decomposes this slice into its parts.
fn get(&self, idx: usize) -> &u4
Gets a nibble at the given index.
fn len(&self) -> usize
Gets the length of the slice.
fn is_empty(&self) -> bool
Checks if the slice is empty.
fn into_generic(&self) -> NibSlice
Converts this slice into a NibSlice
.
fn is_aligned(&self) -> bool
Checks whether this slice is aligned to a byte boundary.
fn is_even(&self) -> bool
Checks whether this slice has an even number of nibbles.
fn is_odd(&self) -> bool
Checks whether this slice has an odd number of nibbles.
Implementors
impl<A: Array<Item = u4x2>> NibSliceExt for NibArrayVec<A>
impl<A: Array<Item = u4x2>> NibSliceExt for NibArrayEven<A>
impl<A: Array<Item = u4x2>> NibSliceExt for NibArrayOdd<A>
impl<A: Array<Item = u4x2>> NibSliceExt for NibArray<A>
impl NibSliceExt for NibSliceFull
impl NibSliceExt for NibSliceNoR
impl NibSliceExt for NibSliceNoL
impl NibSliceExt for NibSliceNoBoth
impl<'a> NibSliceExt for NibSliceAligned<'a>
impl<'a> NibSliceExt for NibSliceAlignedMut<'a>
impl<'a> NibSliceExt for NibSliceUnaligned<'a>
impl<'a> NibSliceExt for NibSliceUnalignedMut<'a>
impl<'a> NibSliceExt for NibSliceEven<'a>
impl<'a> NibSliceExt for NibSliceEvenMut<'a>
impl<'a> NibSliceExt for NibSliceOdd<'a>
impl<'a> NibSliceExt for NibSliceOddMut<'a>
impl<'a> NibSliceExt for NibSlice<'a>
impl<'a> NibSliceExt for NibSliceMut<'a>
impl NibSliceExt for NibVec