pub struct RiskEngineConfigBuilder<S: State = Empty> { /* private fields */ }Expand description
Use builder syntax to set the inputs and finish with build_inner().
Implementations§
Source§impl<S: State> RiskEngineConfigBuilder<S>
impl<S: State> RiskEngineConfigBuilder<S>
Sourcepub fn bypass(self, value: bool) -> RiskEngineConfigBuilder<SetBypass<S>>where
S::Bypass: IsUnset,
pub fn bypass(self, value: bool) -> RiskEngineConfigBuilder<SetBypass<S>>where
S::Bypass: IsUnset,
Sourcepub fn maybe_bypass(
self,
value: Option<bool>,
) -> RiskEngineConfigBuilder<SetBypass<S>>where
S::Bypass: IsUnset,
pub fn maybe_bypass(
self,
value: Option<bool>,
) -> RiskEngineConfigBuilder<SetBypass<S>>where
S::Bypass: IsUnset,
Sourcepub fn max_order_submit(
self,
value: RateLimit,
) -> RiskEngineConfigBuilder<SetMaxOrderSubmit<S>>where
S::MaxOrderSubmit: IsUnset,
pub fn max_order_submit(
self,
value: RateLimit,
) -> RiskEngineConfigBuilder<SetMaxOrderSubmit<S>>where
S::MaxOrderSubmit: IsUnset,
Sourcepub fn maybe_max_order_submit(
self,
value: Option<RateLimit>,
) -> RiskEngineConfigBuilder<SetMaxOrderSubmit<S>>where
S::MaxOrderSubmit: IsUnset,
pub fn maybe_max_order_submit(
self,
value: Option<RateLimit>,
) -> RiskEngineConfigBuilder<SetMaxOrderSubmit<S>>where
S::MaxOrderSubmit: IsUnset,
Sourcepub fn max_order_modify(
self,
value: RateLimit,
) -> RiskEngineConfigBuilder<SetMaxOrderModify<S>>where
S::MaxOrderModify: IsUnset,
pub fn max_order_modify(
self,
value: RateLimit,
) -> RiskEngineConfigBuilder<SetMaxOrderModify<S>>where
S::MaxOrderModify: IsUnset,
Sourcepub fn maybe_max_order_modify(
self,
value: Option<RateLimit>,
) -> RiskEngineConfigBuilder<SetMaxOrderModify<S>>where
S::MaxOrderModify: IsUnset,
pub fn maybe_max_order_modify(
self,
value: Option<RateLimit>,
) -> RiskEngineConfigBuilder<SetMaxOrderModify<S>>where
S::MaxOrderModify: IsUnset,
Sourcepub fn max_notional_per_order(
self,
value: AHashMap<InstrumentId, Decimal>,
) -> RiskEngineConfigBuilder<SetMaxNotionalPerOrder<S>>where
S::MaxNotionalPerOrder: IsUnset,
pub fn max_notional_per_order(
self,
value: AHashMap<InstrumentId, Decimal>,
) -> RiskEngineConfigBuilder<SetMaxNotionalPerOrder<S>>where
S::MaxNotionalPerOrder: IsUnset,
Sourcepub fn maybe_max_notional_per_order(
self,
value: Option<AHashMap<InstrumentId, Decimal>>,
) -> RiskEngineConfigBuilder<SetMaxNotionalPerOrder<S>>where
S::MaxNotionalPerOrder: IsUnset,
pub fn maybe_max_notional_per_order(
self,
value: Option<AHashMap<InstrumentId, Decimal>>,
) -> RiskEngineConfigBuilder<SetMaxNotionalPerOrder<S>>where
S::MaxNotionalPerOrder: IsUnset,
Sourcepub fn debug(self, value: bool) -> RiskEngineConfigBuilder<SetDebug<S>>where
S::Debug: IsUnset,
pub fn debug(self, value: bool) -> RiskEngineConfigBuilder<SetDebug<S>>where
S::Debug: IsUnset,
Sourcepub fn maybe_debug(
self,
value: Option<bool>,
) -> RiskEngineConfigBuilder<SetDebug<S>>where
S::Debug: IsUnset,
pub fn maybe_debug(
self,
value: Option<bool>,
) -> RiskEngineConfigBuilder<SetDebug<S>>where
S::Debug: IsUnset,
Source§impl<S: IsComplete> RiskEngineConfigBuilder<S>
impl<S: IsComplete> RiskEngineConfigBuilder<S>
Sourcepub fn build(self) -> ConfigResult<RiskEngineConfig>
pub fn build(self) -> ConfigResult<RiskEngineConfig>
Validates and builds the RiskEngineConfig.
§Errors
Returns a [ConfigError] if any field fails validation
(see RiskEngineConfig::validate).
Auto Trait Implementations§
impl<S> Freeze for RiskEngineConfigBuilder<S>
impl<S> RefUnwindSafe for RiskEngineConfigBuilder<S>
impl<S> Send for RiskEngineConfigBuilder<S>
impl<S> Sync for RiskEngineConfigBuilder<S>
impl<S> Unpin for RiskEngineConfigBuilder<S>
impl<S> UnsafeUnpin for RiskEngineConfigBuilder<S>
impl<S> UnwindSafe for RiskEngineConfigBuilder<S>
Blanket Implementations§
impl<T> Allocation for T
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