pub enum PeerConnState {
Ourself,
Connected,
Waiting(usize, Instant),
Trying(usize),
Abandonned,
}Expand description
PeerConnState: possible states for our tentative connections to given peer This structure is only interested in recording connection info for outgoing TCP connections
Variants§
Ourself
This entry represents ourself (the local node)
Connected
We currently have a connection to this peer
Waiting(usize, Instant)
Our next connection tentative (the nth, where n is the first value of the tuple) will be at given Instant
Trying(usize)
A connection tentative is in progress (the nth, where n is the value stored)
Abandonned
We abandonned trying to connect to this peer (too many failed attempts)
Implementations§
Trait Implementations§
Source§impl Clone for PeerConnState
impl Clone for PeerConnState
Source§fn clone(&self) -> PeerConnState
fn clone(&self) -> PeerConnState
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 PeerConnState
impl Debug for PeerConnState
Source§impl PartialEq for PeerConnState
impl PartialEq for PeerConnState
impl Copy for PeerConnState
impl Eq for PeerConnState
impl StructuralPartialEq for PeerConnState
Auto Trait Implementations§
impl Freeze for PeerConnState
impl RefUnwindSafe for PeerConnState
impl Send for PeerConnState
impl Sync for PeerConnState
impl Unpin for PeerConnState
impl UnwindSafe for PeerConnState
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