pub trait Concatenate<G: Scope, D: Container> {
// Required method
fn concatenate<I>(&self, sources: I) -> StreamCore<G, D>
where I: IntoIterator<Item = StreamCore<G, D>>;
}
Expand description
Merge the contents of multiple streams.
Required Methods§
sourcefn concatenate<I>(&self, sources: I) -> StreamCore<G, D>where
I: IntoIterator<Item = StreamCore<G, D>>,
fn concatenate<I>(&self, sources: I) -> StreamCore<G, D>where I: IntoIterator<Item = StreamCore<G, D>>,
Merge the contents of multiple streams.
Examples
use timely::dataflow::operators::{ToStream, Concatenate, Inspect};
timely::example(|scope| {
let streams = vec![(0..10).to_stream(scope),
(0..10).to_stream(scope),
(0..10).to_stream(scope)];
scope.concatenate(streams)
.inspect(|x| println!("seen: {:?}", x));
});