Struct bv::adapter::BitFill [−][src]
pub struct BitFill<Block> { /* fields omitted */ }
Emulates a constant-valued bit-vector of a given size.
Methods
impl<Block: BlockType> BitFill<Block>
[src]
impl<Block: BlockType> BitFill<Block>
pub fn zeroes(len: u64) -> Self
[src]
pub fn zeroes(len: u64) -> Self
Constructs a compact bit-vector-like of len
0s.
pub fn ones(len: u64) -> Self
[src]
pub fn ones(len: u64) -> Self
Constructs a compact bit-vector-like of len
1s.
Trait Implementations
impl<Block: Debug> Debug for BitFill<Block>
[src]
impl<Block: Debug> Debug for BitFill<Block>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<Block: Clone> Clone for BitFill<Block>
[src]
impl<Block: Clone> Clone for BitFill<Block>
fn clone(&self) -> BitFill<Block>
[src]
fn clone(&self) -> BitFill<Block>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl<Block: BlockType> Bits for BitFill<Block>
[src]
impl<Block: BlockType> Bits for BitFill<Block>
type Block = Block
The underlying block type used to store the bits of the vector.
fn bit_len(&self) -> u64
[src]
fn bit_len(&self) -> u64
The length of the slice in bits.
fn get_bit(&self, position: u64) -> bool
[src]
fn get_bit(&self, position: u64) -> bool
Gets the bit at position
Read more
fn get_block(&self, position: usize) -> Self::Block
[src]
fn get_block(&self, position: usize) -> Self::Block
Gets the block at position
Read more
fn get_bits(&self, position: u64, len: usize) -> Self::Block
[src]
fn get_bits(&self, position: u64, len: usize) -> Self::Block
Gets count
bits starting at bit index start
, interpreted as a little-endian integer. Read more
fn block_len(&self) -> usize
[src]
fn block_len(&self) -> usize
The length of the slice in blocks.
fn to_bit_vec(&self) -> BitVec<Self::Block>
[src]
fn to_bit_vec(&self) -> BitVec<Self::Block>
Copies the bits into a new allocated [BitVec
]. Read more
impl<T: Bits> PartialEq<T> for BitFill<T::Block>
[src]
impl<T: Bits> PartialEq<T> for BitFill<T::Block>
fn eq(&self, other: &T) -> bool
[src]
fn eq(&self, other: &T) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl<Block: BlockType> Index<u64> for BitFill<Block>
[src]
impl<Block: BlockType> Index<u64> for BitFill<Block>
type Output = bool
The returned type after indexing.
fn index(&self, index: u64) -> &bool
[src]
fn index(&self, index: u64) -> &bool
Performs the indexing (container[index]
) operation.
impl<Block: BlockType> BitSliceable<Range<u64>> for BitFill<Block>
[src]
impl<Block: BlockType> BitSliceable<Range<u64>> for BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: Range<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: Range<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<Block: BlockType> BitSliceable<RangeFrom<u64>> for BitFill<Block>
[src]
impl<Block: BlockType> BitSliceable<RangeFrom<u64>> for BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeFrom<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeFrom<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<Block: BlockType> BitSliceable<RangeTo<u64>> for BitFill<Block>
[src]
impl<Block: BlockType> BitSliceable<RangeTo<u64>> for BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeTo<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeTo<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<Block: BlockType> BitSliceable<RangeFull> for BitFill<Block>
[src]
impl<Block: BlockType> BitSliceable<RangeFull> for BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, _range: RangeFull) -> Self::Slice
[src]
fn bit_slice(self, _range: RangeFull) -> Self::Slice
Slices or re-slices the given object. Read more
impl<Block: BlockType> BitSliceable<RangeInclusive<u64>> for BitFill<Block>
[src]
impl<Block: BlockType> BitSliceable<RangeInclusive<u64>> for BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeInclusive<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeInclusive<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<Block: BlockType> BitSliceable<RangeToInclusive<u64>> for BitFill<Block>
[src]
impl<Block: BlockType> BitSliceable<RangeToInclusive<u64>> for BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeToInclusive<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeToInclusive<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<'a, Block: BlockType> BitSliceable<Range<u64>> for &'a BitFill<Block>
[src]
impl<'a, Block: BlockType> BitSliceable<Range<u64>> for &'a BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: Range<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: Range<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<'a, Block: BlockType> BitSliceable<RangeFrom<u64>> for &'a BitFill<Block>
[src]
impl<'a, Block: BlockType> BitSliceable<RangeFrom<u64>> for &'a BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeFrom<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeFrom<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<'a, Block: BlockType> BitSliceable<RangeTo<u64>> for &'a BitFill<Block>
[src]
impl<'a, Block: BlockType> BitSliceable<RangeTo<u64>> for &'a BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeTo<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeTo<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<'a, Block: BlockType> BitSliceable<RangeFull> for &'a BitFill<Block>
[src]
impl<'a, Block: BlockType> BitSliceable<RangeFull> for &'a BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, _range: RangeFull) -> Self::Slice
[src]
fn bit_slice(self, _range: RangeFull) -> Self::Slice
Slices or re-slices the given object. Read more
impl<'a, Block: BlockType> BitSliceable<RangeInclusive<u64>> for &'a BitFill<Block>
[src]
impl<'a, Block: BlockType> BitSliceable<RangeInclusive<u64>> for &'a BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeInclusive<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeInclusive<u64>) -> Self::Slice
Slices or re-slices the given object. Read more
impl<'a, Block: BlockType> BitSliceable<RangeToInclusive<u64>> for &'a BitFill<Block>
[src]
impl<'a, Block: BlockType> BitSliceable<RangeToInclusive<u64>> for &'a BitFill<Block>
type Slice = BitSliceAdapter<Self>
The type of the slice produced.
fn bit_slice(self, range: RangeToInclusive<u64>) -> Self::Slice
[src]
fn bit_slice(self, range: RangeToInclusive<u64>) -> Self::Slice
Slices or re-slices the given object. Read more