pub struct BudgetState {
pub limit: u64,
pub consumed: u64,
pub exhausted: bool,
}Expand description
In-memory state for one (task, dimension) budget entry.
Fields§
§limit: u64Maximum consumption allowed before dispatch is blocked.
consumed: u64Total consumption recorded so far.
exhausted: boolTrue once consumption has reached or exceeded the limit.
Trait Implementations§
Source§impl Clone for BudgetState
impl Clone for BudgetState
Source§fn clone(&self) -> BudgetState
fn clone(&self) -> BudgetState
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 BudgetState
impl RefUnwindSafe for BudgetState
impl Send for BudgetState
impl Sync for BudgetState
impl Unpin for BudgetState
impl UnsafeUnpin for BudgetState
impl UnwindSafe for BudgetState
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