pub struct Guard(/* private fields */);Expand description
Guard to access key-value pairs
Implementations§
Source§impl Guard
impl Guard
Sourcepub fn into_inner_if(
self,
pred: impl Fn(&UserKey) -> bool,
) -> Result<(UserKey, Option<UserValue>)>
pub fn into_inner_if( self, pred: impl Fn(&UserKey) -> bool, ) -> Result<(UserKey, Option<UserValue>)>
Accesses the key-value pair if the predicate returns true.
The predicate receives the key - if returning false, the value
may not be loaded if the tree is key-value separated.
§Errors
Will return Err if an IO error occurs.
Sourcepub fn into_inner(self) -> Result<KvPair>
pub fn into_inner(self) -> Result<KvPair>
Auto Trait Implementations§
impl Freeze for Guard
impl !RefUnwindSafe for Guard
impl Send for Guard
impl Sync for Guard
impl Unpin for Guard
impl !UnwindSafe for Guard
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