pub struct MemoryKV { /* private fields */ }Expand description
An in-memory key-value store.
Implementations§
Source§impl MemoryKV
impl MemoryKV
Sourcepub fn memory_stats(&self) -> MemoryStats
pub fn memory_stats(&self) -> MemoryStats
Returns current in-memory usage statistics.
Sourcepub fn new_with_limit(limit: Option<usize>) -> Self
pub fn new_with_limit(limit: Option<usize>) -> Self
Creates a new in-memory KV store with an optional memory limit.
Trait Implementations§
Source§impl KVStore for MemoryKV
impl KVStore for MemoryKV
Source§type Transaction<'a> = MemoryTransaction<'a>
type Transaction<'a> = MemoryTransaction<'a>
The transaction type for this store.
Source§type Manager<'a> = &'a MemoryTxnManager
type Manager<'a> = &'a MemoryTxnManager
The transaction manager for this store.
Source§fn txn_manager(&self) -> Self::Manager<'_>
fn txn_manager(&self) -> Self::Manager<'_>
Returns the transaction manager for this store.
Auto Trait Implementations§
impl Freeze for MemoryKV
impl RefUnwindSafe for MemoryKV
impl Send for MemoryKV
impl Sync for MemoryKV
impl Unpin for MemoryKV
impl UnwindSafe for MemoryKV
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