pub struct Snapshot<'db> { /* private fields */ }Expand description
An immutable snapshot of the database state at a particular sequence number.
Obtained via Db::get_snapshot and passed via ReadOptions::snapshot to pin reads to a
specific point in time. The snapshot is released automatically when it is dropped; compaction
is then free to discard entries that were only retained because of it.
See include/leveldb/db.h: DB::GetSnapshot.
Trait Implementations§
Auto Trait Implementations§
impl<'db> Freeze for Snapshot<'db>
impl<'db> !RefUnwindSafe for Snapshot<'db>
impl<'db> Send for Snapshot<'db>
impl<'db> Sync for Snapshot<'db>
impl<'db> Unpin for Snapshot<'db>
impl<'db> UnsafeUnpin for Snapshot<'db>
impl<'db> !UnwindSafe for Snapshot<'db>
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