pub struct ConnectionMetrics {
pub bytes_sent: u64,
pub bytes_received: u64,
pub rtt: Option<Duration>,
pub packet_loss: f64,
}
Expand description
Basic per-connection performance metrics
Fields§
§bytes_sent: u64
Bytes sent to this peer
bytes_received: u64
Bytes received from this peer
rtt: Option<Duration>
Round-trip time
packet_loss: f64
Packet loss rate (0.0 to 1.0)
Trait Implementations§
Source§impl Clone for ConnectionMetrics
impl Clone for ConnectionMetrics
Source§fn clone(&self) -> ConnectionMetrics
fn clone(&self) -> ConnectionMetrics
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 moreAuto Trait Implementations§
impl Freeze for ConnectionMetrics
impl RefUnwindSafe for ConnectionMetrics
impl Send for ConnectionMetrics
impl Sync for ConnectionMetrics
impl Unpin for ConnectionMetrics
impl UnwindSafe for ConnectionMetrics
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