pub struct StrategyBuilder<E = (), X = ()> { /* private fields */ }Expand description
Builder for creating custom strategies with entry/exit conditions.
The builder enforces that both entry and exit conditions are provided before a strategy can be built.
Implementations§
Source§impl StrategyBuilder<(), ()>
impl StrategyBuilder<(), ()>
Source§impl<X> StrategyBuilder<(), X>
impl<X> StrategyBuilder<(), X>
Source§impl<E> StrategyBuilder<E, ()>
impl<E> StrategyBuilder<E, ()>
Source§impl<E: Condition, X: Condition> StrategyBuilder<E, X>
impl<E: Condition, X: Condition> StrategyBuilder<E, X>
Sourcepub fn with_short<SE: Condition, SX: Condition>(
self,
entry: SE,
exit: SX,
) -> Self
pub fn with_short<SE: Condition, SX: Condition>( self, entry: SE, exit: SX, ) -> Self
Sourcepub fn build(self) -> CustomStrategy<E, X>
pub fn build(self) -> CustomStrategy<E, X>
Auto Trait Implementations§
impl<E, X> Freeze for StrategyBuilder<E, X>
impl<E = (), X = ()> !RefUnwindSafe for StrategyBuilder<E, X>
impl<E, X> Send for StrategyBuilder<E, X>
impl<E, X> Sync for StrategyBuilder<E, X>
impl<E, X> Unpin for StrategyBuilder<E, X>
impl<E, X> UnsafeUnpin for StrategyBuilder<E, X>where
E: UnsafeUnpin,
X: UnsafeUnpin,
impl<E = (), X = ()> !UnwindSafe for StrategyBuilder<E, X>
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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> ⓘ
Converts
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> ⓘ
Converts
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