pub struct ConnectionStateMachine { /* private fields */ }Implementations§
Source§impl ConnectionStateMachine
impl ConnectionStateMachine
pub fn new(reconnect_config: ReconnectConfig) -> Self
pub fn state(&self) -> ConnectionState
pub fn info(&self) -> &ConnectionInfo
pub fn reconnect_config(&self) -> &ReconnectConfig
pub fn set_reconnect_config(&mut self, config: ReconnectConfig)
pub fn transition(&mut self, event: &ConnectionEvent) -> ConnectionState
pub fn set_connection_info(&mut self, info: ConnectionInfo)
pub fn is_connected(&self) -> bool
pub fn should_reconnect(&self) -> bool
pub fn next_reconnect_delay(&self) -> Option<Duration>
Trait Implementations§
Source§impl Clone for ConnectionStateMachine
impl Clone for ConnectionStateMachine
Source§fn clone(&self) -> ConnectionStateMachine
fn clone(&self) -> ConnectionStateMachine
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ConnectionStateMachine
impl Debug for ConnectionStateMachine
Auto Trait Implementations§
impl Freeze for ConnectionStateMachine
impl RefUnwindSafe for ConnectionStateMachine
impl Send for ConnectionStateMachine
impl Sync for ConnectionStateMachine
impl Unpin for ConnectionStateMachine
impl UnwindSafe for ConnectionStateMachine
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