Trait bittle::Bits [−][src]
pub trait Bits: Sized + Copy + Eq + Ord + Hash {
type Iter: Iterator<Item = usize>;
const EMPTY: Self;
const FULL: Self;
fn test(&self, index: usize) -> bool;
fn set(&mut self, index: usize);
fn unset(&mut self, index: usize);
fn clear(&mut self);
fn merge(&mut self, other: &Self);
fn iter(self) -> Self::Iter;
}
Expand description
The trait for a bit pattern.
Associated Types
The iterator over this bit pattern.
See FixedSet::iter.
Associated Constants
Bit-pattern for an empty bit pattern.
See FixedSet::empty.
Bit-pattern for a full bit pattern.
See FixedSet::full.
Required methods
Test if the given bit is set.
See FixedSet::test.
Set the given bit in the bit pattern.
See FixedSet::set.
Unset the given bit in the bit pattern.
See FixedSet::unset.
Clear the entire bit pattern.
See FixedSet::clear.
Merge these bits with another.
See FixedSet::merge.
Construct an iterator over a bit pattern.
See FixedSet::iter.