pub struct OrderedLeafBuilder<K, R, C = Vec<(K, R)>>where
    C: BatchContainer<Item = (K, R)> + Deref<Target = [(K, R)]>,{
    pub vals: C,
}
Expand description

A builder for unordered values.

Fields§

§vals: C

Unordered values.

Trait Implementations§

source§

impl<K: Ord + Clone, R: Semigroup + Clone, C> Builder for OrderedLeafBuilder<K, R, C>where C: BatchContainer<Item = (K, R)> + Deref<Target = [(K, R)]>,

§

type Trie = OrderedLeaf<K, R, C>

The type of collection produced.
source§

fn boundary(&mut self) -> usize

Requests a commitment to the offset of the current-most sub-collection. Read more
source§

fn done(self) -> Self::Trie

Finalizes the building process and returns the collection.
source§

impl<K: Ord + Clone, R: Semigroup + Clone, C> MergeBuilder for OrderedLeafBuilder<K, R, C>where C: BatchContainer<Item = (K, R)> + Deref<Target = [(K, R)]>,

source§

fn with_capacity(other1: &Self::Trie, other2: &Self::Trie) -> Self

Allocates an instance of the builder with sufficient capacity to contain the merged data.
source§

fn copy_range(&mut self, other: &Self::Trie, lower: usize, upper: usize)

Copies sub-collections of other into this collection.
source§

fn push_merge( &mut self, other1: (&Self::Trie, usize, usize), other2: (&Self::Trie, usize, usize) ) -> usize

Merges two sub-collections into one sub-collection.
source§

impl<K: Ord + Clone, R: Semigroup + Clone, C> TupleBuilder for OrderedLeafBuilder<K, R, C>where C: BatchContainer<Item = (K, R)> + Deref<Target = [(K, R)]>,

§

type Item = (K, R)

The type of item accepted for construction.
source§

fn new() -> Self

Allocates a new builder.
source§

fn with_capacity(cap: usize) -> Self

Allocates a new builder with capacity for at least cap tuples.
source§

fn push_tuple(&mut self, tuple: (K, R))

Inserts a new into the collection.

Auto Trait Implementations§

§

impl<K, R, C> RefUnwindSafe for OrderedLeafBuilder<K, R, C>where C: RefUnwindSafe,

§

impl<K, R, C> Send for OrderedLeafBuilder<K, R, C>where C: Send,

§

impl<K, R, C> Sync for OrderedLeafBuilder<K, R, C>where C: Sync,

§

impl<K, R, C> Unpin for OrderedLeafBuilder<K, R, C>where C: Unpin,

§

impl<K, R, C> UnwindSafe for OrderedLeafBuilder<K, R, C>where C: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.