Trait timely::dataflow::operators::enterleave::EnterAt
[−]
[src]
pub trait EnterAt<G: Scope, T: Timestamp, D: Data> where G::Timestamp: Hash, T: Hash { fn enter_at<F: Fn(&D) -> T + 'static>(&self, scope: &Child<G, T>, initial: F) -> Stream<Child<G, T>, D>; }
Extension trait to move a Stream
into a child of its current Scope
setting the timestamp for each element.
Required Methods
fn enter_at<F: Fn(&D) -> T + 'static>(&self, scope: &Child<G, T>, initial: F) -> Stream<Child<G, T>, D>
Moves the Stream
argument into a child of its current Scope
setting the timestamp for each element by initial
.
Examples
use timely::dataflow::scopes::Scope; use timely::dataflow::operators::{EnterAt, Leave, ToStream}; timely::example(|outer| { let stream = (0..9).to_stream(outer); let output = outer.scoped::<u32,_,_>(|inner| { stream.enter_at(inner, |x| *x).leave() }); });