Skip to main content

DataBitVec

Trait DataBitVec 

Source
pub trait DataBitVec: Clone {
Show 13 methods // Required methods fn spawn(&self, capacity: usize) -> Self; fn push(&mut self, bit: bool); fn get(&self, idx: usize) -> bool; fn set(&mut self, idx: usize, value: bool); fn len(&self) -> usize; fn clear(&mut self); fn extend_from(&mut self, other: &Self); fn count_ones(&self) -> usize; fn iter(&self) -> impl Iterator<Item = bool> + '_; fn capacity(&self) -> usize; // Provided methods fn is_empty(&self) -> bool { ... } fn count_zeros(&self) -> usize { ... } fn take(&self, n: usize) -> Self { ... }
}
Expand description

Trait for bitvec-like storage (null masks and boolean data).

Required Methods§

Source

fn spawn(&self, capacity: usize) -> Self

Source

fn push(&mut self, bit: bool)

Source

fn get(&self, idx: usize) -> bool

Source

fn set(&mut self, idx: usize, value: bool)

Source

fn len(&self) -> usize

Source

fn clear(&mut self)

Source

fn extend_from(&mut self, other: &Self)

Source

fn count_ones(&self) -> usize

Source

fn iter(&self) -> impl Iterator<Item = bool> + '_

Source

fn capacity(&self) -> usize

Provided Methods§

Source

fn is_empty(&self) -> bool

Source

fn count_zeros(&self) -> usize

Source

fn take(&self, n: usize) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§