pub struct InFlightPacket {
pub sequence: u64,
pub sent_at: Instant,
pub retransmit_count: u32,
}Expand description
Tracks a sent-but-unacknowledged packet.
Fields§
§sequence: u64Sequence number of the packet.
sent_at: InstantWhen this packet was sent.
retransmit_count: u32Number of times this packet has been retransmitted.
Implementations§
Source§impl InFlightPacket
impl InFlightPacket
Sourcepub fn is_timed_out(&self, rto: Duration) -> bool
pub fn is_timed_out(&self, rto: Duration) -> bool
Returns true if this packet has exceeded the retransmission timeout.
Trait Implementations§
Source§impl Clone for InFlightPacket
impl Clone for InFlightPacket
Source§fn clone(&self) -> InFlightPacket
fn clone(&self) -> InFlightPacket
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 InFlightPacket
impl RefUnwindSafe for InFlightPacket
impl Send for InFlightPacket
impl Sync for InFlightPacket
impl Unpin for InFlightPacket
impl UnsafeUnpin for InFlightPacket
impl UnwindSafe for InFlightPacket
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