pub struct LocalNodeInfo {
pub moniker: String,
pub peer_id: PeerId,
pub listen_addr: Multiaddr,
pub consensus_address: Option<String>,
pub is_validator: bool,
pub persistent_peers_only: bool,
pub subscribed_topics: HashSet<String>,
}Expand description
Local node information
Fields§
§moniker: String§peer_id: PeerId§listen_addr: Multiaddr§consensus_address: Option<String>This node’s consensus address (if it is configured with validator credentials).
Present if the node has a consensus keypair, even if not currently in the active validator set. This is static configuration determined at startup. Note: In the future full nodes will not have a consensus address, so this will be None.
is_validator: boolWhether this node is currently in the active validator set.
Updated dynamically when validator set changes. A node can have consensus_address = Some(...)
but is_validator = false if it was removed from the validator set or hasn’t joined yet.
persistent_peers_only: boolWhether this node only accepts connections from persistent peers.
subscribed_topics: HashSet<String>Trait Implementations§
Source§impl Clone for LocalNodeInfo
impl Clone for LocalNodeInfo
Source§fn clone(&self) -> LocalNodeInfo
fn clone(&self) -> LocalNodeInfo
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 LocalNodeInfo
impl Debug for LocalNodeInfo
Auto Trait Implementations§
impl Freeze for LocalNodeInfo
impl RefUnwindSafe for LocalNodeInfo
impl Send for LocalNodeInfo
impl Sync for LocalNodeInfo
impl Unpin for LocalNodeInfo
impl UnsafeUnpin for LocalNodeInfo
impl UnwindSafe for LocalNodeInfo
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
Converts
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>
Converts
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 more