Struct succinct::JacobsonRank
[−]
[src]
pub struct JacobsonRank<'a, Store: ?Sized + Bits + 'a> { // some fields omitted }
Add-on to Bits
to support fast rank queries.
Construct with JacobsonRank::new
.
Methods
impl<'a, Store: Bits + ?Sized + 'a> JacobsonRank<'a, Store>
[src]
fn new(bits: &'a Store) -> Self
Creates a new rank support structure for the given bit vector.
Trait Implementations
impl<'a, Store: Debug + ?Sized + Bits + 'a> Debug for JacobsonRank<'a, Store>
[src]
impl<'a, Store: Clone + ?Sized + Bits + 'a> Clone for JacobsonRank<'a, Store>
[src]
fn clone(&self) -> JacobsonRank<'a, Store>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<'a, Store: ?Sized + Bits + 'a> Bits for JacobsonRank<'a, Store>
[src]
type Block = Store::Block
The underlying block type used to store the bits of the slice.
fn block_len(&self) -> usize
The length of the slice in blocks.
fn bit_len(&self) -> u64
The length of the slice in bits.
fn get_block(&self, index: usize) -> Self::Block
Gets the block at position
Read more
fn get_bit(&self, index: u64) -> bool
Gets the bit at position
Read more
fn get_bits(&self, start: u64, count: usize) -> Self::Block
Gets count
bits starting at bit index start
, interpreted as a little-endian integer. Read more
impl<'a, Store: ?Sized + Bits + 'a> RankSupport for JacobsonRank<'a, Store>
[src]
type Over = bool
The type of value to rank.
fn rank(&self, position: u64, value: bool) -> u64
Returns the rank of the given value at a given position. Read more
fn limit(&self) -> u64
The size of the vector being ranked. Read more
impl<'a, Store: ?Sized + Bits + 'a> BitRankSupport for JacobsonRank<'a, Store>
[src]
fn rank1(&self, position: u64) -> u64
Returns the rank of 1 at the given position. Read more
fn rank0(&self, position: u64) -> u64
Returns the rank of 0 at the given position. Read more
impl<'a, Store: ?Sized + Bits + 'a> SpaceUsage for JacobsonRank<'a, Store>
[src]
fn is_stack_only() -> bool
Is the size of this type known statically? Read more
fn heap_bytes(&self) -> usize
Calculates the heap portion of the size of an object. Read more
fn total_bytes(&self) -> usize
Computes the size of the receiver in bytes. Read more
fn stack_bytes() -> usize
Calculates the stack portion of the size of this type. Read more