pub struct PartialArrayBuilder<T, B> { /* private fields */ }Expand description
Builder for creating an immutable partial array.
The builder allows you to specify the array length and then add (position, value) pairs. Positions must be added in strictly increasing order.
To get a builder you can use either new_dense or new_sparse.
Implementations§
Source§impl<T> PartialArrayBuilder<T, EliasFanoBuilder>
impl<T> PartialArrayBuilder<T, EliasFanoBuilder>
Trait Implementations§
Source§impl<T: Clone, B: Clone> Clone for PartialArrayBuilder<T, B>
impl<T: Clone, B: Clone> Clone for PartialArrayBuilder<T, B>
Source§fn clone(&self) -> PartialArrayBuilder<T, B>
fn clone(&self) -> PartialArrayBuilder<T, B>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<T> Extend<(usize, T)> for PartialArrayBuilder<T, BitVec<Box<[usize]>>>
Extends the builder with an iterator of (position, value) pairs.
impl<T> Extend<(usize, T)> for PartialArrayBuilder<T, BitVec<Box<[usize]>>>
Extends the builder with an iterator of (position, value) pairs.
Position must be in strictly increasing order. The first returned position must be greater than the last position set.
Source§fn extend<I: IntoIterator<Item = (usize, T)>>(&mut self, iter: I)
fn extend<I: IntoIterator<Item = (usize, T)>>(&mut self, iter: I)
Extends a collection with the contents of an iterator. Read more
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one)Extends a collection with exactly one element.
Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one)Reserves capacity in a collection for the given number of additional elements. Read more
Source§impl<T> Extend<(usize, T)> for PartialArrayBuilder<T, EliasFanoBuilder>
Extends the builder with an iterator of (position, value) pairs.
impl<T> Extend<(usize, T)> for PartialArrayBuilder<T, EliasFanoBuilder>
Extends the builder with an iterator of (position, value) pairs.
Position must be in strictly increasing order. The first returned position must be greater than the last position set.
Source§fn extend<I: IntoIterator<Item = (usize, T)>>(&mut self, iter: I)
fn extend<I: IntoIterator<Item = (usize, T)>>(&mut self, iter: I)
Extends a collection with the contents of an iterator. Read more
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one)Extends a collection with exactly one element.
Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one)Reserves capacity in a collection for the given number of additional elements. Read more
Source§impl<T, B> FlatType for PartialArrayBuilder<T, B>
impl<T, B> FlatType for PartialArrayBuilder<T, B>
Source§impl<T, B> MemDbgImpl for PartialArrayBuilder<T, B>
impl<T, B> MemDbgImpl for PartialArrayBuilder<T, B>
fn _mem_dbg_rec_on( &self, _memdbg_writer: &mut impl Write, _memdbg_total_size: usize, _memdbg_max_depth: usize, _memdbg_prefix: &mut String, _memdbg_is_last: bool, _memdbg_flags: DbgFlags, _memdbg_refs: &mut HashSet<usize>, ) -> Result
fn _mem_dbg_depth_on( &self, writer: &mut impl Write, total_size: usize, max_depth: usize, prefix: &mut String, field_name: Option<&str>, is_last: bool, padded_size: usize, flags: DbgFlags, dbg_refs: &mut HashSet<usize>, ) -> Result<(), Error>
Source§fn _mem_dbg_depth_on_impl(
&self,
writer: &mut impl Write,
total_size: usize,
max_depth: usize,
prefix: &mut String,
field_name: Option<&str>,
is_last: bool,
padded_size: usize,
flags: DbgFlags,
dbg_refs: &mut HashSet<usize>,
ref_display: RefDisplay,
) -> Result<(), Error>
fn _mem_dbg_depth_on_impl( &self, writer: &mut impl Write, total_size: usize, max_depth: usize, prefix: &mut String, field_name: Option<&str>, is_last: bool, padded_size: usize, flags: DbgFlags, dbg_refs: &mut HashSet<usize>, ref_display: RefDisplay, ) -> Result<(), Error>
Internal implementation for depth display. Read more
Auto Trait Implementations§
impl<T, B> Freeze for PartialArrayBuilder<T, B>where
B: Freeze,
impl<T, B> RefUnwindSafe for PartialArrayBuilder<T, B>where
B: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, B> Send for PartialArrayBuilder<T, B>
impl<T, B> Sync for PartialArrayBuilder<T, B>
impl<T, B> Unpin for PartialArrayBuilder<T, B>
impl<T, B> UnsafeUnpin for PartialArrayBuilder<T, B>where
B: UnsafeUnpin,
impl<T, B> UnwindSafe for PartialArrayBuilder<T, B>where
B: UnwindSafe,
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T, U> CastableInto<U> for Twhere
U: CastableFrom<T>,
impl<T, U> CastableInto<U> for Twhere
U: CastableFrom<T>,
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DowncastableFrom<T> for T
impl<T> DowncastableFrom<T> for T
Source§fn downcast_from(value: T) -> T
fn downcast_from(value: T) -> T
Truncate the current UnsignedInt to a possibly smaller size
Source§impl<T, U> DowncastableInto<U> for Twhere
U: DowncastableFrom<T>,
impl<T, U> DowncastableInto<U> for Twhere
U: DowncastableFrom<T>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> MemDbg for Twhere
T: MemDbgImpl,
impl<T> MemDbg for Twhere
T: MemDbgImpl,
Source§fn mem_dbg(&self, flags: DbgFlags) -> Result<(), Error>
fn mem_dbg(&self, flags: DbgFlags) -> Result<(), Error>
Available on crate feature
std only.Writes to stderr debug info about the structure memory usage, expanding
all levels of nested structures.
Source§fn mem_dbg_on(
&self,
writer: &mut impl Write,
flags: DbgFlags,
) -> Result<(), Error>
fn mem_dbg_on( &self, writer: &mut impl Write, flags: DbgFlags, ) -> Result<(), Error>
Writes to a
core::fmt::Write debug info about the structure memory
usage, expanding all levels of nested structures.Source§fn mem_dbg_depth(&self, max_depth: usize, flags: DbgFlags) -> Result<(), Error>
fn mem_dbg_depth(&self, max_depth: usize, flags: DbgFlags) -> Result<(), Error>
Available on crate feature
std only.Writes to stderr debug info about the structure memory usage as
mem_dbg, but expanding only up to max_depth
levels of nested structures.Source§fn mem_dbg_depth_on(
&self,
writer: &mut impl Write,
max_depth: usize,
flags: DbgFlags,
) -> Result<(), Error>
fn mem_dbg_depth_on( &self, writer: &mut impl Write, max_depth: usize, flags: DbgFlags, ) -> Result<(), Error>
Writes to a
core::fmt::Write debug info about the structure memory
usage as mem_dbg_on, but expanding only up to
max_depth levels of nested structures.Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> UpcastableFrom<T> for T
impl<T> UpcastableFrom<T> for T
Source§fn upcast_from(value: T) -> T
fn upcast_from(value: T) -> T
Extend the current UnsignedInt to a possibly bigger size.