pub struct WriteBatch { /* private fields */ }Expand description
An atomic write batch that collects operations and commits them in a single call.
Implementations§
Source§impl WriteBatch
impl WriteBatch
Sourcepub fn insert<V>(
&mut self,
ks: &KeyspaceHandle,
key: impl Into<Vec<u8>>,
value: &V,
) -> Result<(), AppError>where
V: Serialize,
pub fn insert<V>(
&mut self,
ks: &KeyspaceHandle,
key: impl Into<Vec<u8>>,
value: &V,
) -> Result<(), AppError>where
V: Serialize,
Add a serializable insert to the batch.
Sourcepub fn insert_raw(
&mut self,
ks: &KeyspaceHandle,
key: impl Into<Vec<u8>>,
value: impl Into<Vec<u8>>,
)
pub fn insert_raw( &mut self, ks: &KeyspaceHandle, key: impl Into<Vec<u8>>, value: impl Into<Vec<u8>>, )
Add a raw-bytes insert to the batch.
Auto Trait Implementations§
impl !RefUnwindSafe for WriteBatch
impl !Sync for WriteBatch
impl !UnwindSafe for WriteBatch
impl Freeze for WriteBatch
impl Send for WriteBatch
impl Unpin for WriteBatch
impl UnsafeUnpin for WriteBatch
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