pub struct ScanByLabel { /* private fields */ }Expand description
Yields chunks of node slot numbers for a single label.
Each output chunk contains one COL_ID_SLOT column with at most
CHUNK_CAPACITY consecutive slot numbers.
Phase 2: uses a cursor-based approach (next_slot/end_slot) rather than
pre-allocating the entire Vec<u64> at construction time. This reduces
startup allocation from O(hwm) to O(1) — critical for large labels.
Implementations§
Source§impl ScanByLabel
impl ScanByLabel
Sourcepub fn new(hwm: u64) -> Self
pub fn new(hwm: u64) -> Self
Create a ScanByLabel operator.
hwm — high-water mark from NodeStore::hwm_for_label(label_id).
Emits slot numbers 0..hwm in order, allocating at most one chunk at a time.
Sourcepub fn from_slots(slots: Vec<u64>) -> Self
pub fn from_slots(slots: Vec<u64>) -> Self
Create from a pre-built slot list (for tests and custom scan patterns).
Retained for backward compatibility with existing unit tests and
special scan patterns. Prefer ScanByLabel::new for production use.
Trait Implementations§
Source§impl PipelineOperator for ScanByLabel
impl PipelineOperator for ScanByLabel
Auto Trait Implementations§
impl Freeze for ScanByLabel
impl RefUnwindSafe for ScanByLabel
impl Send for ScanByLabel
impl Sync for ScanByLabel
impl Unpin for ScanByLabel
impl UnsafeUnpin for ScanByLabel
impl UnwindSafe for ScanByLabel
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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 more