pub struct DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>where
Sc: Score,{ /* private fields */ }Expand description
Directed self-join over projected rows, pairing left with right when
KL(left) == KR(right); produced by
Stream::join with equal_bi(..).
Implementations§
Source§impl<S, Out, K, Src, F, KL, KR, PF, Sc> DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
Sourcepub fn filter<P>(
self,
predicate: P,
) -> DirectedBi<S, Out, K, Src, F, KL, KR, AndBiFilter<PF, FnBiFilter<impl Fn(&S, &Out, &Out, usize, usize) -> bool + Send + Sync>>, Sc>
pub fn filter<P>( self, predicate: P, ) -> DirectedBi<S, Out, K, Src, F, KL, KR, AndBiFilter<PF, FnBiFilter<impl Fn(&S, &Out, &Out, usize, usize) -> bool + Send + Sync>>, Sc>
Keeps only pairs for which predicate returns true, after the existing filter.
Sourcepub fn penalize<W>(
self,
weight: W,
) -> DirectedBiBuilder<S, Out, K, Src, F, KL, KR, PF, impl Fn(&Out, &Out) -> Sc + Send + Sync, Sc>
pub fn penalize<W>( self, weight: W, ) -> DirectedBiBuilder<S, Out, K, Src, F, KL, KR, PF, impl Fn(&Out, &Out) -> Sc + Send + Sync, Sc>
Penalizes each match by weight.
weight is a fixed score, or a closure over the matched (&Out, &Out) pair returning one.
A fixed weight with a non-zero hard level marks the constraint hard; closures
are soft unless wrapped in hard_weight.
Sourcepub fn reward<W>(
self,
weight: W,
) -> DirectedBiBuilder<S, Out, K, Src, F, KL, KR, PF, impl Fn(&Out, &Out) -> Sc + Send + Sync, Sc>
pub fn reward<W>( self, weight: W, ) -> DirectedBiBuilder<S, Out, K, Src, F, KL, KR, PF, impl Fn(&Out, &Out) -> Sc + Send + Sync, Sc>
Rewards each match by weight.
weight is a fixed score, or a closure over the matched (&Out, &Out) pair returning one.
A fixed weight with a non-zero hard level marks the constraint hard; closures
are soft unless wrapped in hard_weight.
Auto Trait Implementations§
impl<S, Out, K, Src, F, KL, KR, PF, Sc> Forget for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> Freeze for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> Move for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> RefUnwindSafe for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>where
Src: RefUnwindSafe,
F: RefUnwindSafe,
KL: RefUnwindSafe,
KR: RefUnwindSafe,
PF: RefUnwindSafe,
PhantomData<(fn() -> S, fn() -> Out, fn() -> K, fn() -> Sc)>: RefUnwindSafe,
impl<S, Out, K, Src, F, KL, KR, PF, Sc> Send for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> Sync for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> Unpin for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>
impl<S, Out, K, Src, F, KL, KR, PF, Sc> UnsafeUnpin for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>where
Src: UnsafeUnpin,
F: UnsafeUnpin,
KL: UnsafeUnpin,
KR: UnsafeUnpin,
PF: UnsafeUnpin,
PhantomData<(fn() -> S, fn() -> Out, fn() -> K, fn() -> Sc)>: UnsafeUnpin,
impl<S, Out, K, Src, F, KL, KR, PF, Sc> UnwindSafe for DirectedBi<S, Out, K, Src, F, KL, KR, PF, Sc>where
Src: UnwindSafe,
F: UnwindSafe,
KL: UnwindSafe,
KR: UnwindSafe,
PF: UnwindSafe,
PhantomData<(fn() -> S, fn() -> Out, fn() -> K, fn() -> Sc)>: UnwindSafe,
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
Mutably borrows from an owned value. Read more