pub struct OperatorBuilder<'scope, T: Timestamp> { /* private fields */ }Expand description
Builds operators with generic shape.
Implementations§
Source§impl<'scope, T: Timestamp> OperatorBuilder<'scope, T>
impl<'scope, T: Timestamp> OperatorBuilder<'scope, T>
Sourcepub fn new(name: String, scope: Scope<'scope, T>) -> Self
pub fn new(name: String, scope: Scope<'scope, T>) -> Self
Allocates a new generic operator builder from its containing scope.
Sourcepub fn shape(&self) -> &OperatorShape
pub fn shape(&self) -> &OperatorShape
Return a reference to the operator’s shape
Sourcepub fn set_notify_for(&mut self, input: usize, notify: FrontierInterest)
pub fn set_notify_for(&mut self, input: usize, notify: FrontierInterest)
Sets frontier interest for a specific input.
Sourcepub fn new_input<C: Container, P>(
&mut self,
stream: Stream<'scope, T, C>,
pact: P,
) -> P::Pullerwhere
P: ParallelizationContract<T, C>,
pub fn new_input<C: Container, P>(
&mut self,
stream: Stream<'scope, T, C>,
pact: P,
) -> P::Pullerwhere
P: ParallelizationContract<T, C>,
Adds a new input to a generic operator builder, returning the Pull implementor to use.
Sourcepub fn new_input_connection<C: Container, P, I>(
&mut self,
stream: Stream<'scope, T, C>,
pact: P,
connection: I,
) -> P::Pullerwhere
P: ParallelizationContract<T, C>,
I: IntoIterator<Item = (usize, Antichain<<T as Timestamp>::Summary>)>,
pub fn new_input_connection<C: Container, P, I>(
&mut self,
stream: Stream<'scope, T, C>,
pact: P,
connection: I,
) -> P::Pullerwhere
P: ParallelizationContract<T, C>,
I: IntoIterator<Item = (usize, Antichain<<T as Timestamp>::Summary>)>,
Adds a new input to a generic operator builder, returning the Pull implementor to use.
Sourcepub fn new_output<C: Container>(&mut self) -> (Tee<T, C>, Stream<'scope, T, C>)
pub fn new_output<C: Container>(&mut self) -> (Tee<T, C>, Stream<'scope, T, C>)
Adds a new output to a generic operator builder, returning the Push implementor to use.
Sourcepub fn new_output_connection<C: Container, I>(
&mut self,
connection: I,
) -> (Tee<T, C>, Stream<'scope, T, C>)
pub fn new_output_connection<C: Container, I>( &mut self, connection: I, ) -> (Tee<T, C>, Stream<'scope, T, C>)
Adds a new output to a generic operator builder, returning the Push implementor to use.
Sourcepub fn build<L>(self, logic: L)
pub fn build<L>(self, logic: L)
Creates an operator implementation from supplied logic constructor.
Boxes the closure to avoid per-closure monomorphization based on L.
For the fully generic (non-boxing) path, see [build_typed].
Sourcepub fn build_boxed(self, logic: Box<dyn FnMut(&mut SharedProgress<T>) -> bool>)
pub fn build_boxed(self, logic: Box<dyn FnMut(&mut SharedProgress<T>) -> bool>)
Creates an operator implementation from pre-boxed logic.
This method exists primarily to force the Box<dyn ...> coercion, which
can otherwise easily be Box<L> for specialized L instead.
Sourcepub fn build_typed<L>(self, logic: L)
pub fn build_typed<L>(self, logic: L)
Like build_reschedule, but specialized to the closure type L.
This method is instantiated once per distinct L, and one should be
mindful of monomorphization bloat. Callers with many distinct closures
should consider erasing their variation, for example via Box<dyn ...>,
as demonstrated in [build].
Sourcepub fn operator_info(&self) -> OperatorInfo
pub fn operator_info(&self) -> OperatorInfo
Information describing the operator.
Trait Implementations§
Auto Trait Implementations§
impl<'scope, T> Freeze for OperatorBuilder<'scope, T>
impl<'scope, T> !RefUnwindSafe for OperatorBuilder<'scope, T>
impl<'scope, T> !Send for OperatorBuilder<'scope, T>
impl<'scope, T> !Sync for OperatorBuilder<'scope, T>
impl<'scope, T> Unpin for OperatorBuilder<'scope, T>
impl<'scope, T> UnsafeUnpin for OperatorBuilder<'scope, T>
impl<'scope, T> !UnwindSafe for OperatorBuilder<'scope, T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more