pub struct PeerStats {
created: SystemTime,
last_block_received: Option<SystemTime>,
last_fragment_received: Option<SystemTime>,
last_gossip_received: Option<SystemTime>,
}
Fields§
§created: SystemTime
§last_block_received: Option<SystemTime>
§last_fragment_received: Option<SystemTime>
§last_gossip_received: Option<SystemTime>
Implementations§
source§impl PeerStats
impl PeerStats
pub fn last_block_received(&self) -> Option<SystemTime>
pub fn last_fragment_received(&self) -> Option<SystemTime>
pub fn last_gossip_received(&self) -> Option<SystemTime>
fn update_last_block_received(&mut self, timestamp: SystemTime)
fn update_last_fragment_received(&mut self, timestamp: SystemTime)
fn update_last_gossip_received(&mut self, timestamp: SystemTime)
pub fn connection_established(&self) -> SystemTime
pub fn last_activity(&self) -> SystemTime
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for PeerStats
impl Send for PeerStats
impl Sync for PeerStats
impl Unpin for PeerStats
impl UnwindSafe for PeerStats
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
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request