pub struct Storage;
Trait Implementations§
Source§impl<'a, K, V> AsIterator<'a, K, V> for Storage
impl<'a, K, V> AsIterator<'a, K, V> for Storage
Source§impl<K, V> Batch<K, V> for Storage
impl<K, V> Batch<K, V> for Storage
Source§impl BatchBuilder for Storage
impl BatchBuilder for Storage
Source§type Batch = StorageBatch
type Batch = StorageBatch
Type that acts like a memory buffer which queue all the write operations.
Source§fn batch_commit(
&self,
_batch: Self::Batch,
_durability: bool,
) -> Result<(), Self::Error>
fn batch_commit( &self, _batch: Self::Batch, _durability: bool, ) -> Result<(), Self::Error>
Takes ownership of a batch object in order to commit it to the backend.
Durability argument determines if the batch needs to be logged into a write ahead log or not.
Source§fn batch_begin() -> Self::Batch
fn batch_begin() -> Self::Batch
Creates and returns the constraint
Batch
object.Source§impl<'a, K: 'a, V: 'a> MultiFetch<'a, K, V> for Storage
impl<'a, K: 'a, V: 'a> MultiFetch<'a, K, V> for Storage
Source§impl StorageBackend for Storage
impl StorageBackend for Storage
Source§type ConfigBuilder = ()
type ConfigBuilder = ()
Helps build the associated
Config
.Source§type Error = Infallible
type Error = Infallible
Returned on failed operations.
Source§fn start(_config: Self::Config) -> Result<Self, Self::Error>
fn start(_config: Self::Config) -> Result<Self, Self::Error>
Initializes and starts the backend.
Source§fn size(&self) -> Result<Option<usize>, Self::Error>
fn size(&self) -> Result<Option<usize>, Self::Error>
Returns the size of the database in bytes.
Not all backends may be able to provide this operation.
Source§fn get_health(&self) -> Result<Option<StorageHealth>, Self::Error>
fn get_health(&self) -> Result<Option<StorageHealth>, Self::Error>
Returns the health status of the database.
Not all backends may be able to provide this operation.
Source§fn set_health(&self, _health: StorageHealth) -> Result<(), Self::Error>
fn set_health(&self, _health: StorageHealth) -> Result<(), Self::Error>
Sets the health status of the database.
Not all backends may be able to provide this operation.
Auto Trait Implementations§
impl Freeze for Storage
impl RefUnwindSafe for Storage
impl Send for Storage
impl Sync for Storage
impl Unpin for Storage
impl UnwindSafe for Storage
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