pub struct NetworkConditions { /* private fields */ }Expand description
Determines the network conditions for an ALPINE streaming session.
Implementations§
Source§impl NetworkConditions
impl NetworkConditions
Sourcepub fn record_frame(&mut self, sequence: u64, arrival_us: u64, deadline_us: u64)
pub fn record_frame(&mut self, sequence: u64, arrival_us: u64, deadline_us: u64)
Records an observed frame arrival.
The stream encodes sequence, arrival_us, and the caller-supplied
deadline_us so we can independently reason about lateness, loss, and
jitter. All calculations are deterministic and rely solely on these
inputs.
Sourcepub fn metrics(&self) -> NetworkMetrics
pub fn metrics(&self) -> NetworkMetrics
Returns the latest metrics snapshot.
Sourcepub fn max_loss_gap(&self) -> u64
pub fn max_loss_gap(&self) -> u64
Returns the largest sequence gap observed for burst detection.
Auto Trait Implementations§
impl Freeze for NetworkConditions
impl RefUnwindSafe for NetworkConditions
impl Send for NetworkConditions
impl Sync for NetworkConditions
impl Unpin for NetworkConditions
impl UnwindSafe for NetworkConditions
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