pub struct MemoryDriver { /* private fields */ }Expand description
In-process memory driver.
Implementations§
Source§impl MemoryDriver
impl MemoryDriver
Trait Implementations§
Source§impl Clone for MemoryDriver
impl Clone for MemoryDriver
Source§fn clone(&self) -> MemoryDriver
fn clone(&self) -> MemoryDriver
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MemoryDriver
impl Debug for MemoryDriver
Source§impl Default for MemoryDriver
impl Default for MemoryDriver
Source§fn default() -> MemoryDriver
fn default() -> MemoryDriver
Returns the “default value” for a type. Read more
Source§impl Driver for MemoryDriver
impl Driver for MemoryDriver
Source§fn capabilities(&self) -> Capabilities
fn capabilities(&self) -> Capabilities
Reports supported driver behaviour.
Source§fn initialise<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn initialise<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Prepares the driver for use.
Source§fn finalise<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn finalise<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Releases driver resources.
Source§fn get<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
options: &'life4 ReadOptions,
) -> Pin<Box<dyn Future<Output = Result<Option<StoredValue>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn get<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
options: &'life4 ReadOptions,
) -> Pin<Box<dyn Future<Output = Result<Option<StoredValue>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Reads a stored value.
Source§fn set<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
value: StoredValue,
options: &'life4 WriteOptions,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn set<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
value: StoredValue,
options: &'life4 WriteOptions,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Writes a stored value.
Source§fn delete<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
options: &'life4 DeleteOptions,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn delete<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
options: &'life4 DeleteOptions,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Deletes a stored value and returns whether a value was removed.
Source§fn exists<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn exists<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
key: &'life3 Key,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Returns whether a stored value exists.
Source§fn scan_prefix<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
options: &'life3 ScanOptions,
) -> Pin<Box<dyn Future<Output = Result<Vec<(Key, StoredValue)>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn scan_prefix<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
namespace: &'life1 Namespace,
collection: &'life2 CollectionName,
options: &'life3 ScanOptions,
) -> Pin<Box<dyn Future<Output = Result<Vec<(Key, StoredValue)>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Scans values by key prefix.
Auto Trait Implementations§
impl !RefUnwindSafe for MemoryDriver
impl !UnwindSafe for MemoryDriver
impl Freeze for MemoryDriver
impl Send for MemoryDriver
impl Sync for MemoryDriver
impl Unpin for MemoryDriver
impl UnsafeUnpin for MemoryDriver
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