pub struct PersyDatabase { /* private fields */ }
Implementations§
Trait Implementations§
Source§impl KeyValueDB for PersyDatabase
impl KeyValueDB for PersyDatabase
Source§fn get_by_prefix(&self, col: u32, prefix: &[u8]) -> Result<Option<DBValue>>
fn get_by_prefix(&self, col: u32, prefix: &[u8]) -> Result<Option<DBValue>>
Get the first value matching the given prefix.
Source§fn write(&self, transaction: DBTransaction) -> Result<()>
fn write(&self, transaction: DBTransaction) -> Result<()>
Write a transaction of changes to the backing store.
Source§fn iter<'a>(
&'a self,
col: u32,
) -> Box<dyn Iterator<Item = Result<DBKeyValue>> + 'a>
fn iter<'a>( &'a self, col: u32, ) -> Box<dyn Iterator<Item = Result<DBKeyValue>> + 'a>
Iterate over the data for a given column.
Source§fn iter_with_prefix<'a>(
&'a self,
col: u32,
prefix: &'a [u8],
) -> Box<dyn Iterator<Item = Result<DBKeyValue>> + 'a>
fn iter_with_prefix<'a>( &'a self, col: u32, prefix: &'a [u8], ) -> Box<dyn Iterator<Item = Result<DBKeyValue>> + 'a>
Iterate over the data for a given column, returning all key/value pairs
where the key starts with the given prefix.
Source§fn transaction(&self) -> DBTransaction
fn transaction(&self) -> DBTransaction
Helper to create a new transaction.
Auto Trait Implementations§
impl Freeze for PersyDatabase
impl !RefUnwindSafe for PersyDatabase
impl Send for PersyDatabase
impl Sync for PersyDatabase
impl Unpin for PersyDatabase
impl !UnwindSafe for PersyDatabase
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