pub struct LeaseGuard { /* private fields */ }Expand description
Active short-term reservation against the budget.
While alive, the effective per-cache target is reduced by
bytes(). The reduction is released when the guard is dropped.
Issued by MemoryBudget::lease.
The guard holds a Weak reference to the budget so that a guard
outliving its budget does not leak the budget’s allocation.
Implementations§
Trait Implementations§
Source§impl Drop for LeaseGuard
impl Drop for LeaseGuard
Auto Trait Implementations§
impl !RefUnwindSafe for LeaseGuard
impl !UnwindSafe for LeaseGuard
impl Freeze for LeaseGuard
impl Send for LeaseGuard
impl Sync for LeaseGuard
impl Unpin for LeaseGuard
impl UnsafeUnpin for LeaseGuard
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