pub enum LeaseRequest<K> {
Acquire {
holder: K,
duration: Duration,
},
Renew {
holder: K,
generation: TimerGeneration,
duration: Duration,
},
Release {
holder: K,
generation: TimerGeneration,
},
}Expand description
Complete lease operation retained when admission is rejected.
Variants§
Acquire
Attempt to acquire a vacant lease.
Renew
Attempt to renew one exact held generation.
Release
Attempt to release one exact held generation.
Trait Implementations§
Source§impl<K: Clone> Clone for LeaseRequest<K>
impl<K: Clone> Clone for LeaseRequest<K>
Source§fn clone(&self) -> LeaseRequest<K>
fn clone(&self) -> LeaseRequest<K>
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 moreSource§impl<K: Debug> Debug for LeaseRequest<K>
impl<K: Debug> Debug for LeaseRequest<K>
Source§impl<K: PartialEq> PartialEq for LeaseRequest<K>
impl<K: PartialEq> PartialEq for LeaseRequest<K>
impl<K: Eq> Eq for LeaseRequest<K>
impl<K> StructuralPartialEq for LeaseRequest<K>
Auto Trait Implementations§
impl<K> Freeze for LeaseRequest<K>where
K: Freeze,
impl<K> RefUnwindSafe for LeaseRequest<K>where
K: RefUnwindSafe,
impl<K> Send for LeaseRequest<K>where
K: Send,
impl<K> Sync for LeaseRequest<K>where
K: Sync,
impl<K> Unpin for LeaseRequest<K>where
K: Unpin,
impl<K> UnsafeUnpin for LeaseRequest<K>where
K: UnsafeUnpin,
impl<K> UnwindSafe for LeaseRequest<K>where
K: UnwindSafe,
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