pub struct Skip {
pub input: NodeId,
pub bound: Start,
pub output: Cell<Option<OutEdge>>,
}Expand description
Skip: a stateless, ordered operator that drops rows up to bound (the AST
start). Stateless ⇒ no StorageId.
Fields§
§input: NodeIdUpstream input operator (always the source connection in the built subset —
start is lowered right after the source, mirroring buildPipelineInternal).
bound: StartThe start bound: rows at/after it survive, per its Start::basis
(Basis::At includes the bound row, Basis::After excludes it). The
builder lowers the AST start (a name-keyed partial row + exclusive) to
this positional Start; the comparator only reads the sort columns.
output: Cell<Option<OutEdge>>The single downstream edge as a port-carrying OutEdge (like a
Join’s): Port::Single to a terminal sink, or
Port::JoinParent when this Skip feeds the parent port of a relationship
join stacked above it. Wired two-phase via
Graph::set_output (Single) or
Graph::set_out_edge (explicit port).
Implementations§
Source§impl Skip
impl Skip
pub fn new(input: NodeId, bound: Start) -> Skip
Sourcepub fn fetch<'g>(
&'g self,
g: &'g Graph,
req: &FetchRequest,
) -> Box<dyn Iterator<Item = Node<'g>> + 'g>
pub fn fetch<'g>( &'g self, g: &'g Graph, req: &FetchRequest, ) -> Box<dyn Iterator<Item = Node<'g>> + 'g>
Lazy pull (skip.ts:53): merge the bound into the input start and fetch.
Forward scans pass the input through (the source’s start gate did the work);
reverse scans additionally take_while rows that are still at/after the
bound, stopping at the first that falls below it.
Sourcepub fn push<'g>(&'g self, g: &'g Graph, change: Change<'g>)
pub fn push<'g>(&'g self, g: &'g Graph, change: Change<'g>)
Eager push (skip.ts:88): forward Add/Remove/Child iff their row is at/after
the bound; split an Edit that crosses the bound into Remove(old)/Add(new)
(maybe-split-and-push-edit-change.ts). Forwards on the edge’s own port so a
Skip can feed a relationship join’s parent port.