Skip to main content

take

Function take 

Source
pub fn take(core: &Core, source: NodeId, count: u32) -> FlowRegistration
Expand description

take(source, count) — emits the first count DATA values then self-completes via Core::complete. When upstream completes before count is reached, the standard auto-cascade propagates COMPLETE.

count == 0 is allowed (D027): the first fire emits zero items then immediately self-completes — subscribers see [Start, Complete] (no Dirty precedes the terminal because no Data is emitted on this wave; the canonical-spec one-DIRTY-per-wave rule (R1.3.1.a) governs DATA waves, not pure-terminal waves).