pub struct Dict { /* private fields */ }Expand description
High-performance in-memory dictionary
The core storage structure that holds all key-value pairs in memory. Uses SwissTable (hashbrown) with AHash for fast lookups and supports all Redis-compatible operations.
Implementations§
Source§impl Dict
impl Dict
Sourcepub fn set(&self, k: Bytes, v: Value)
pub fn set(&self, k: Bytes, v: Value)
Set a key-value pair
Inserts or updates a key with the given value. If key already exists, the old value is replaced.
§Arguments
k- Key as owned Bytesv- Value to store
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Dict
impl Freeze for Dict
impl Send for Dict
impl Sync for Dict
impl Unpin for Dict
impl UnsafeUnpin for Dict
impl UnwindSafe for Dict
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