pub struct BandwidthStats {
pub current_tokens: u64,
pub capacity: u64,
pub refill_rate_bytes_per_sec: u64,
}Expand description
Bandwidth usage statistics for the token bucket
Fields§
§current_tokens: u64Current number of available tokens (bytes that can be sent)
capacity: u64Maximum token bucket capacity (burst allowance)
refill_rate_bytes_per_sec: u64Token refill rate in bytes per second
Trait Implementations§
Source§impl Clone for BandwidthStats
impl Clone for BandwidthStats
Source§fn clone(&self) -> BandwidthStats
fn clone(&self) -> BandwidthStats
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 BandwidthStats
impl RefUnwindSafe for BandwidthStats
impl Send for BandwidthStats
impl Sync for BandwidthStats
impl Unpin for BandwidthStats
impl UnwindSafe for BandwidthStats
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