pub struct EngineBuilder<A: Application = NoOpApplication> { /* private fields */ }Expand description
Builder for configuring a FIX engine.
Implementations§
Source§impl<A: Application> EngineBuilder<A>
impl<A: Application> EngineBuilder<A>
Sourcepub fn with_application<B: Application>(
self,
application: B,
) -> EngineBuilder<B>
pub fn with_application<B: Application>( self, application: B, ) -> EngineBuilder<B>
Sets the application callback handler.
Sourcepub fn add_session(self, config: SessionConfig) -> Self
pub fn add_session(self, config: SessionConfig) -> Self
Adds a session configuration.
Sourcepub fn with_connect_timeout(self, timeout: Duration) -> Self
pub fn with_connect_timeout(self, timeout: Duration) -> Self
Sets the connection timeout.
Sourcepub fn with_reconnect_interval(self, interval: Duration) -> Self
pub fn with_reconnect_interval(self, interval: Duration) -> Self
Sets the reconnect interval.
Sourcepub const fn with_max_reconnect_attempts(self, attempts: u32) -> Self
pub const fn with_max_reconnect_attempts(self, attempts: u32) -> Self
Sets the maximum reconnect attempts.
Sourcepub fn sessions(&self) -> &[SessionConfig]
pub fn sessions(&self) -> &[SessionConfig]
Returns the configured sessions.
Sourcepub const fn connect_timeout(&self) -> Duration
pub const fn connect_timeout(&self) -> Duration
Returns the connection timeout.
Sourcepub const fn reconnect_interval(&self) -> Duration
pub const fn reconnect_interval(&self) -> Duration
Returns the reconnect interval.
Sourcepub const fn max_reconnect_attempts(&self) -> u32
pub const fn max_reconnect_attempts(&self) -> u32
Returns the maximum reconnect attempts.
Sourcepub fn application(&self) -> Arc<A>
pub fn application(&self) -> Arc<A>
Returns the application handler.
Trait Implementations§
Source§impl<A: Debug + Application> Debug for EngineBuilder<A>
impl<A: Debug + Application> Debug for EngineBuilder<A>
Source§impl Default for EngineBuilder<NoOpApplication>
impl Default for EngineBuilder<NoOpApplication>
Auto Trait Implementations§
impl<A> Freeze for EngineBuilder<A>
impl<A> RefUnwindSafe for EngineBuilder<A>where
A: RefUnwindSafe,
impl<A> Send for EngineBuilder<A>
impl<A> Sync for EngineBuilder<A>
impl<A> Unpin for EngineBuilder<A>
impl<A> UnwindSafe for EngineBuilder<A>where
A: RefUnwindSafe,
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