pub struct TxRwRef<'tx> { /* private fields */ }Expand description
Read/Write Transaction reference used in managed transactions
Trait Implementations§
source§impl<'tx> TxApi<'tx> for TxRwRef<'tx>
impl<'tx> TxApi<'tx> for TxRwRef<'tx>
source§fn size(&self) -> u64
fn size(&self) -> u64
Returns current database size in bytes as seen by this transaction. Read more
source§fn writable(&self) -> bool
fn writable(&self) -> bool
Returns whether the transaction can perform write operations. Read more
source§fn cursor(&self) -> CursorImpl<'tx>
fn cursor(&self) -> CursorImpl<'tx>
Creates a cursor associated with the root bucket.
All items in the cursor will return None value because all root bucket keys point to buckets. Read more
source§fn bucket<T: AsRef<[u8]>>(&self, name: T) -> Option<BucketImpl<'tx>>
fn bucket<T: AsRef<[u8]>>(&self, name: T) -> Option<BucketImpl<'tx>>
Retrieves a bucket by name.
Returns None if the bucket does not exist. Read more
source§impl<'tx> TxRwRefApi<'tx> for TxRwRef<'tx>
impl<'tx> TxRwRefApi<'tx> for TxRwRef<'tx>
source§fn bucket_mut<T: AsRef<[u8]>>(&mut self, name: T) -> Option<BucketRwImpl<'tx>>
fn bucket_mut<T: AsRef<[u8]>>(&mut self, name: T) -> Option<BucketRwImpl<'tx>>
Retrieves a mutable bucket by name. Read more
source§fn create_bucket<T: AsRef<[u8]>>(
&mut self,
name: T
) -> Result<BucketRwImpl<'tx>>
fn create_bucket<T: AsRef<[u8]>>( &mut self, name: T ) -> Result<BucketRwImpl<'tx>>
Creates a new bucket. Read more
source§fn create_bucket_if_not_exists<T: AsRef<[u8]>>(
&mut self,
name: T
) -> Result<BucketRwImpl<'tx>>
fn create_bucket_if_not_exists<T: AsRef<[u8]>>( &mut self, name: T ) -> Result<BucketRwImpl<'tx>>
Creates a new bucket if it doesn’t already exist. Read more
Auto Trait Implementations§
impl<'tx> Freeze for TxRwRef<'tx>
impl<'tx> !RefUnwindSafe for TxRwRef<'tx>
impl<'tx> !Send for TxRwRef<'tx>
impl<'tx> !Sync for TxRwRef<'tx>
impl<'tx> Unpin for TxRwRef<'tx>
impl<'tx> !UnwindSafe for TxRwRef<'tx>
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> 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