Skip to main content

extract_chain

Function extract_chain 

Source
pub fn extract_chain<D, T, R, SinkShip, SinkKeep>(
    merged: FetchIter<'_, D, T, R>,
    upper: AntichainRef<'_, T>,
    frontier: &mut Antichain<T>,
    ship: SinkShip,
    keep: SinkKeep,
    stash: &mut Vec<Column<(D, T, R)>>,
)
where D: Columnar, for<'a> Ref<'a, D>: Copy + Ord, T: Columnar + Default + Clone + PartialOrder, for<'a> Ref<'a, T>: Copy + Ord, R: Columnar + Default + Semigroup + for<'a> Semigroup<Ref<'a, R>>, SinkShip: FnMut(PagedColumn<(D, T, R)>), SinkKeep: FnMut(PagedColumn<(D, T, R)>),
Expand description

Streaming extract: walks merged chunk-by-chunk via Column::extract, routing each filled keep/ship chunk through its sink after pageing. Mirrors the per-chunk ship-threshold yield already inside Column::extract.

stash carries recycled Column::Typed buffers in and out so the per-chunk extract loop doesn’t restart from zero capacity each time keep_buf / ship_buf ships and the source buffer is dropped.