pub struct RawMap { /* private fields */ }Expand description
A lock-free ordered map with raw interfaces for advanced use cases.
Implementations§
Source§impl RawMap
impl RawMap
Sourcepub fn get<F>(&self, key: &[u8], lsn: u64, f: F) -> Result<()>
pub fn get<F>(&self, key: &[u8], lsn: u64, f: F) -> Result<()>
Finds the value corresponding to key and calls func with it.
pub fn iter(&self) -> Iter
Sourcepub fn put(&self, key: &[u8], lsn: u64, value: &[u8]) -> Result<()>
pub fn put(&self, key: &[u8], lsn: u64, value: &[u8]) -> Result<()>
Puts the key-value pair into this map.
Sourcepub fn delete(&self, key: &[u8], lsn: u64) -> Result<()>
pub fn delete(&self, key: &[u8], lsn: u64) -> Result<()>
Deletes the key-value pair into this map.
Sourcepub fn set_min_lsn(&self, lsn: u64)
pub fn set_min_lsn(&self, lsn: u64)
Updates the minimal valid LSN for reads.
Entries with smaller LSNs will be dropped later.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RawMap
impl RefUnwindSafe for RawMap
impl Send for RawMap
impl Sync for RawMap
impl Unpin for RawMap
impl UnsafeUnpin for RawMap
impl UnwindSafe for RawMap
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