pub struct SkipMap { /* private fields */ }Implementations§
Source§impl SkipMap
impl SkipMap
Sourcepub fn new_memtable_map(cmp: Rc<Box<dyn Cmp>>) -> SkipMap
pub fn new_memtable_map(cmp: Rc<Box<dyn Cmp>>) -> SkipMap
Returns a SkipMap that wraps the comparator inside a MemtableKeyCmp.
Sourcepub fn new(cmp: Rc<Box<dyn Cmp>>) -> SkipMap
pub fn new(cmp: Rc<Box<dyn Cmp>>) -> SkipMap
Returns a SkipMap that uses the specified comparator.
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn approx_memory(&self) -> usize
pub fn contains(&self, key: &[u8]) -> bool
Sourcepub fn insert(&mut self, key: Vec<u8>, val: Vec<u8>)
pub fn insert(&mut self, key: Vec<u8>, val: Vec<u8>)
inserts a key into the table. key may not be empty.
pub fn iter(&self) -> SkipMapIter
Auto Trait Implementations§
impl Freeze for SkipMap
impl !RefUnwindSafe for SkipMap
impl !Send for SkipMap
impl !Sync for SkipMap
impl Unpin for SkipMap
impl !UnwindSafe for SkipMap
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