pub struct Evicted<K, V> {
pub key: K,
pub value: V,
}Expand description
Information about an evicted cache entry.
When an entry is evicted from the cache, this struct holds both the key and value of the evicted entry. This is particularly useful for cleaning up related resources (like ETags) when entries are evicted.
Fields§
§key: KThe key of the evicted entry
value: VThe value of the evicted entry
Trait Implementations§
Auto Trait Implementations§
impl<K, V> Freeze for Evicted<K, V>
impl<K, V> RefUnwindSafe for Evicted<K, V>where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for Evicted<K, V>
impl<K, V> Sync for Evicted<K, V>
impl<K, V> Unpin for Evicted<K, V>
impl<K, V> UnsafeUnpin for Evicted<K, V>where
K: UnsafeUnpin,
V: UnsafeUnpin,
impl<K, V> UnwindSafe for Evicted<K, V>where
K: UnwindSafe,
V: 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