pub trait ToStreamBuilder {
type Item;
// Required method
fn to_stream_with_builder<'scope, T: Timestamp, CB>(
self,
scope: Scope<'scope, T>,
) -> Stream<'scope, T, CB::Container>
where CB: PushInto<Self::Item> + ContainerBuilder;
}Expand description
Converts to a timely Stream, using a container builder.
Required Associated Types§
Required Methods§
Sourcefn to_stream_with_builder<'scope, T: Timestamp, CB>(
self,
scope: Scope<'scope, T>,
) -> Stream<'scope, T, CB::Container>
fn to_stream_with_builder<'scope, T: Timestamp, CB>( self, scope: Scope<'scope, T>, ) -> Stream<'scope, T, CB::Container>
Converts to a timely Stream, using the supplied container builder type.
§Examples
use timely::dataflow::operators::core::{ToStreamBuilder, Capture};
use timely::dataflow::operators::core::capture::Extract;
use timely::container::CapacityContainerBuilder;
let (data1, data2) = timely::example(|scope| {
let data1 = (0..3).to_stream_with_builder::<_, CapacityContainerBuilder<_>>(scope)
.container::<Vec<_>>()
.capture();
let data2 = vec![0,1,2].to_stream_with_builder::<_, CapacityContainerBuilder<_>>(scope)
.container::<Vec<_>>()
.capture();
(data1, data2)
});
assert_eq!(data1.extract(), data2.extract());Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".