pub struct WriteBatchWithIndex { /* private fields */ }Expand description
A WriteBatch with a secondary sorted index for efficient iteration. Allows iterating over batch contents merged with a DB snapshot.
Implementations§
Source§impl WriteBatchWithIndex
impl WriteBatchWithIndex
pub fn new() -> Self
pub fn put(&mut self, key: &[u8], value: &[u8])
pub fn delete(&mut self, key: &[u8])
pub fn delete_range(&mut self, begin: &[u8], end: &[u8])
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn into_batch(self) -> WriteBatch
Sourcepub fn operation_count(&self) -> u64
pub fn operation_count(&self) -> u64
Total number of operations (point + range-del). Used for sequence number range allocation.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for WriteBatchWithIndex
impl RefUnwindSafe for WriteBatchWithIndex
impl Send for WriteBatchWithIndex
impl Sync for WriteBatchWithIndex
impl Unpin for WriteBatchWithIndex
impl UnsafeUnpin for WriteBatchWithIndex
impl UnwindSafe for WriteBatchWithIndex
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