pub struct Snapshot { /* private fields */ }Implementations§
Source§impl Snapshot
impl Snapshot
pub fn get<Item>( &self, tree: &ReadTree<Item>, id: impl Borrow<Item::SelfId> + Debug, ) -> DbResult<Option<Item>>
pub fn get_or_err<Item>( &self, tree: &ReadTree<Item>, id: impl Borrow<Item::SelfId> + Debug, ) -> DbResult<Item>
pub fn contains<Item>( &self, tree: &ReadTree<Item>, id: impl Borrow<Item::SelfId> + Debug, ) -> DbResult<bool>
pub fn size_of<Item>( &self, tree: &ReadTree<Item>, id: impl Borrow<Item::SelfId> + Debug, ) -> DbResult<Option<u32>>
pub fn first<Item>( &self, tree: &ReadTree<Item>, ) -> DbResult<Option<Entry<Item>>>
pub fn last<Item>(&self, tree: &ReadTree<Item>) -> DbResult<Option<Entry<Item>>>
pub fn iter<Item>(&self, tree: &ReadTree<Item>) -> IterTree<Entry<Item>>
pub fn keys<Item>( &self, tree: &ReadTree<Item>, ) -> impl DoubleEndedIterator<Item = Item::SelfId>
pub fn range<Item, K, R>( &self, tree: &ReadTree<Item>, range: R, ) -> IterTree<Entry<Item>>
pub fn prefix<Item, P>( &self, tree: &ReadTree<Item>, prefix: P, ) -> IterTree<Entry<Item>>
pub fn prefix_key<Item, P>( &self, tree: &ReadTree<Item>, prefix: P, ) -> IterTree<Item::SelfId>
pub fn try_iter<Item>(&self, tree: &ReadTree<Item>) -> TryIterTree<Entry<Item>>
pub fn try_range<Item, K, R>( &self, tree: &ReadTree<Item>, range: R, ) -> TryIterTree<ItemWithRaw<Item>>
pub fn try_prefix<Item, P>( &self, tree: &ReadTree<Item>, prefix: P, ) -> TryIterTree<Entry<Item>>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Snapshot
impl !RefUnwindSafe for Snapshot
impl Send for Snapshot
impl Sync for Snapshot
impl Unpin for Snapshot
impl UnsafeUnpin for Snapshot
impl !UnwindSafe for Snapshot
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more