Struct s2n_quic_transport::recovery::Manager
source · [−]pub struct Manager<Config: Config> { /* private fields */ }
Implementations
sourceimpl<Config: Config> Manager<Config>
impl<Config: Config> Manager<Config>
sourcepub fn new(space: PacketNumberSpace) -> Self
pub fn new(space: PacketNumberSpace) -> Self
Constructs a new recovery::Manager
sourcepub fn on_retry_packet(&mut self, path: &mut Path<Config>)
pub fn on_retry_packet(&mut self, path: &mut Path<Config>)
Invoked when the Client processes a Retry packet.
Reset congestion controller state by discarding sent bytes and replacing recovery manager with a new instance of itself.
pub fn on_timeout<Ctx: Context<Config>, Pub: ConnectionPublisher>(
&mut self,
timestamp: Timestamp,
context: &mut Ctx,
publisher: &mut Pub
)
pub fn on_packet_sent<Ctx: Context<Config>, Pub: ConnectionPublisher>(
&mut self,
packet_number: PacketNumber,
outcome: Outcome,
time_sent: Timestamp,
ecn: ExplicitCongestionNotification,
context: &mut Ctx,
publisher: &mut Pub
)
sourcepub fn update_pto_timer(
&mut self,
path: &Path<Config>,
now: Timestamp,
is_handshake_confirmed: bool
)
pub fn update_pto_timer(
&mut self,
path: &Path<Config>,
now: Timestamp,
is_handshake_confirmed: bool
)
Updates the PTO timer
sourcepub fn on_transmit<W: WriteContext>(&mut self, context: &mut W)
pub fn on_transmit<W: WriteContext>(&mut self, context: &mut W)
Queries the component for any outgoing frames that need to get sent
sourcepub fn on_ack_frame<A: AckRanges, Ctx: Context<Config>, Pub: ConnectionPublisher>(
&mut self,
datagram: &DatagramInfo,
frame: Ack<A>,
context: &mut Ctx,
publisher: &mut Pub
) -> Result<(), Error>
pub fn on_ack_frame<A: AckRanges, Ctx: Context<Config>, Pub: ConnectionPublisher>(
&mut self,
datagram: &DatagramInfo,
frame: Ack<A>,
context: &mut Ctx,
publisher: &mut Pub
) -> Result<(), Error>
Process ACK frame.
Update congestion controller, timers and meta data around acked packet ranges.
sourcepub fn requires_probe(&self) -> bool
pub fn requires_probe(&self) -> bool
Returns true
if the recovery manager requires a probe packet to be sent.
sourcepub fn on_packet_number_space_discarded<Pub: ConnectionPublisher>(
&mut self,
path: &mut Path<Config>,
path_id: Id,
publisher: &mut Pub
)
pub fn on_packet_number_space_discarded<Pub: ConnectionPublisher>(
&mut self,
path: &mut Path<Config>,
path_id: Id,
publisher: &mut Pub
)
Clears bytes in flight for sent packets.
Trait Implementations
sourceimpl<Config: Config> Provider for Manager<Config>
impl<Config: Config> Provider for Manager<Config>
sourcefn timers<Q: Query>(&self, query: &mut Q) -> Result
fn timers<Q: Query>(&self, query: &mut Q) -> Result
Notifies the query of any timers owned by the provider Read more
sourcefn next_expiration(&self) -> Option<Timestamp>
fn next_expiration(&self) -> Option<Timestamp>
Returns the next Timestamp
at which the earliest timer is armed in the provider
sourcefn armed_timer_count(&self) -> usize
fn armed_timer_count(&self) -> usize
Counts the number of armed timers in the provider
sourcefn for_each_timer<F>(&self, f: F) where
F: FnMut(&Timer) -> Result<(), QueryBreak>,
fn for_each_timer<F>(&self, f: F) where
F: FnMut(&Timer) -> Result<(), QueryBreak>,
Iterates over each timer in the provider and calls the provided function
Auto Trait Implementations
impl<Config> RefUnwindSafe for Manager<Config> where
Config: RefUnwindSafe,
impl<Config> Send for Manager<Config>
impl<Config> Sync for Manager<Config> where
Config: Sync,
impl<Config> Unpin for Manager<Config> where
Config: Unpin,
impl<Config> UnwindSafe for Manager<Config> where
Config: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more