#[repr(u8)]pub enum Connectedness {
NotConnected = 0,
Connected = 1,
CanConnect = 2,
CannotConnect = 3,
Limited = 4,
}
Expand description
Represents the connectivity state of a peer in a network, indicating the reachability and interaction status of a node with its peers.
Variants§
NotConnected = 0
No current connection to the peer, and no recent history of a successful connection.
Connected = 1
An active, open connection to the peer exists.
CanConnect = 2
Connection to the peer is possible but not currently established; usually implies a past successful connection.
CannotConnect = 3
Recent attempts to connect to the peer failed, indicating potential issues in reachability or peer status.
Limited = 4
Connection to the peer is limited; may not have full capabilities.
Trait Implementations§
source§impl Clone for Connectedness
impl Clone for Connectedness
source§fn clone(&self) -> Connectedness
fn clone(&self) -> Connectedness
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for Connectedness
impl Debug for Connectedness
source§impl Default for Connectedness
impl Default for Connectedness
source§fn default() -> Connectedness
fn default() -> Connectedness
source§impl<'de> Deserialize<'de> for Connectedness
impl<'de> Deserialize<'de> for Connectedness
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
source§impl Display for Connectedness
impl Display for Connectedness
source§impl From<u8> for Connectedness
impl From<u8> for Connectedness
source§impl PartialEq for Connectedness
impl PartialEq for Connectedness
source§impl Serialize for Connectedness
impl Serialize for Connectedness
impl Copy for Connectedness
impl StructuralPartialEq for Connectedness
Auto Trait Implementations§
impl Freeze for Connectedness
impl RefUnwindSafe for Connectedness
impl Send for Connectedness
impl Sync for Connectedness
impl Unpin for Connectedness
impl UnwindSafe for Connectedness
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)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>
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>
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 moreimpl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 1 byte
Size for each variant:
NotConnected
: 0 bytesConnected
: 0 bytesCanConnect
: 0 bytesCannotConnect
: 0 bytesLimited
: 0 bytes