Struct differential_dataflow::trace::implementations::OffsetList
source · pub struct OffsetList {
pub zero_prefix: usize,
pub smol: Vec<u32>,
pub chonk: Vec<u64>,
}
Expand description
A list of unsigned integers that uses u32
elements as long as they are small enough, and switches to u64
once they are not.
Fields§
§zero_prefix: usize
Length of a prefix of zero elements.
smol: Vec<u32>
Offsets that fit within a u32
.
chonk: Vec<u64>
Offsets that either do not fit in a u32
, or are inserted after some offset that did not fit.
Implementations§
source§impl OffsetList
impl OffsetList
sourcepub fn with_capacity(cap: usize) -> Self
pub fn with_capacity(cap: usize) -> Self
Allocate a new list with a specified capacity.
sourcepub fn push(&mut self, offset: usize)
pub fn push(&mut self, offset: usize)
Inserts the offset, as a u32
if that is still on the table.
Trait Implementations§
source§impl Abomonation for OffsetList
impl Abomonation for OffsetList
source§impl BatchContainer for OffsetList
impl BatchContainer for OffsetList
source§fn copy_range(&mut self, other: &Self, start: usize, end: usize)
fn copy_range(&mut self, other: &Self, start: usize, end: usize)
Extends from a range of items in another
Self
.source§fn with_capacity(size: usize) -> Self
fn with_capacity(size: usize) -> Self
Creates a new container with sufficient capacity.
source§fn merge_capacity(cont1: &Self, cont2: &Self) -> Self
fn merge_capacity(cont1: &Self, cont2: &Self) -> Self
Creates a new container with sufficient capacity.
source§fn index(&self, index: usize) -> Self::ReadItem<'_>
fn index(&self, index: usize) -> Self::ReadItem<'_>
Reference to the element at this position.
source§impl Clone for OffsetList
impl Clone for OffsetList
source§fn clone(&self) -> OffsetList
fn clone(&self) -> OffsetList
Returns a copy 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 Debug for OffsetList
impl Debug for OffsetList
source§impl Ord for OffsetList
impl Ord for OffsetList
source§fn cmp(&self, other: &OffsetList) -> Ordering
fn cmp(&self, other: &OffsetList) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for OffsetList
impl PartialEq for OffsetList
source§fn eq(&self, other: &OffsetList) -> bool
fn eq(&self, other: &OffsetList) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for OffsetList
impl PartialOrd for OffsetList
source§fn partial_cmp(&self, other: &OffsetList) -> Option<Ordering>
fn partial_cmp(&self, other: &OffsetList) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for OffsetList
impl StructuralPartialEq for OffsetList
Auto Trait Implementations§
impl Freeze for OffsetList
impl RefUnwindSafe for OffsetList
impl Send for OffsetList
impl Sync for OffsetList
impl Unpin for OffsetList
impl UnwindSafe for OffsetList
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<R, O, T> CopyOnto<ConsecutiveOffsetPairs<R, O>> for T
impl<R, O, T> CopyOnto<ConsecutiveOffsetPairs<R, O>> for T
source§fn copy_onto(
self,
target: &mut ConsecutiveOffsetPairs<R, O>
) -> <ConsecutiveOffsetPairs<R, O> as Region>::Index
fn copy_onto( self, target: &mut ConsecutiveOffsetPairs<R, O> ) -> <ConsecutiveOffsetPairs<R, O> as Region>::Index
Copy self into the target container, returning an index that allows to
look up the corresponding read item.