Trait isomorphism::bitfield::BitField
[−]
[src]
pub trait BitField: BitAnd<Output = Self> + BitOr<Output = Self> + Copy + Sized { type Iter: Iterator<Item = usize>; fn size() -> usize; fn one_at(index: usize) -> Self; fn zero_at(index: usize) -> Self; fn iter(&self) -> Self::Iter; fn full(&self) -> bool; }
A bit field trait for use in hashmap buckets. See the bitfield
method of BiMapBuilder
for
more information.
Associated Types
Required Methods
fn size() -> usize
Should return a constant value describing how big the bitfield of this type is.
fn one_at(index: usize) -> Self
Should return a bitfield that is all zeroes, except for a single one at a given index.
fn zero_at(index: usize) -> Self
Should return a bitfield that is all ones, except for a single zero at a given index.
fn iter(&self) -> Self::Iter
Return an iterator that iterates through the bitfield, returning the indexes within the bitfield that have 1s in them, in order from least significant to most significant.
fn full(&self) -> bool
Is the bitfield currently full?