pub struct Meter { /* private fields */ }Expand description
The last minute of requests: when each went out, its kind and weight; and when each refusal came.
Implementations§
Source§impl Meter
impl Meter
pub fn record(&mut self, now: u64, kind: &str, weight: u32)
pub fn refuse(&mut self, now: u64)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Meter
impl RefUnwindSafe for Meter
impl Send for Meter
impl Sync for Meter
impl Unpin for Meter
impl UnsafeUnpin for Meter
impl UnwindSafe for Meter
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