#[non_exhaustive]pub struct Snapshot { /* private fields */ }Expand description
A point-in-time, host-level rollup of a registry’s counters, returned
by Registry::snapshot.
Every counter is summed across all broadcasts the registry is tracking and
split by tier and role, plus per-tier connected-session presence. One entry
per tier that recorded any traffic or session, keyed by the tier’s label (so
an idle tier is simply absent). Intended for a scrape / /metrics-style
endpoint where per-broadcast cardinality is unwanted; use
Registry::report for the per-broadcast breakdown. A disabled registry
yields no rows.
Implementations§
Source§impl Snapshot
impl Snapshot
Sourcepub fn control(&self) -> Vec<(Tier, Message, Totals)>
pub fn control(&self) -> Vec<(Tier, Message, Totals)>
The (tier, class, totals) control-message rows with any traffic, sorted by tier and class.
Includes prefixes inside complete codec values, but excludes separately coded type selectors,
media payload, and transport framing, acknowledgements, and retransmissions.
Sourcepub fn traffic(&self) -> Vec<(Tier, Role, Traffic)>
pub fn traffic(&self) -> Vec<(Tier, Role, Traffic)>
The (tier, role, totals) traffic rows, one publisher and one subscriber
row per tier present. Sorted by tier label then role for stable output.
Trait Implementations§
impl Eq for Snapshot
impl StructuralPartialEq for Snapshot
Auto Trait Implementations§
impl Freeze for Snapshot
impl RefUnwindSafe for Snapshot
impl Send for Snapshot
impl Sync for Snapshot
impl Unpin for Snapshot
impl UnsafeUnpin for Snapshot
impl UnwindSafe for Snapshot
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.