pub struct KV<T> {
pub key: u64,
pub data: T,
pub weight: u16,
}
Expand description
The key-value pair returned from cache eviction
Fields§
§key: u64
NOTE: that we currently don’t store the Actual key in the cache. This returned value is just the hash of it.
data: T
§weight: u16
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for KV<T>where
T: Freeze,
impl<T> RefUnwindSafe for KV<T>where
T: RefUnwindSafe,
impl<T> Send for KV<T>where
T: Send,
impl<T> Sync for KV<T>where
T: Sync,
impl<T> Unpin for KV<T>where
T: Unpin,
impl<T> UnwindSafe for KV<T>where
T: 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