pub struct SqliteMemoryStore { /* private fields */ }Expand description
Persistent long-term memory backed by SQLite.
Implementations§
Source§impl SqliteMemoryStore
impl SqliteMemoryStore
pub fn open(path: &str) -> Result<Self, MemoryError>
pub fn in_memory() -> Result<Self, MemoryError>
Trait Implementations§
Source§impl MemoryStore for SqliteMemoryStore
impl MemoryStore for SqliteMemoryStore
fn set<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 str,
value: Value,
) -> Pin<Box<dyn Future<Output = Result<(), MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<MemoryEntry>, MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_keys<'life0, 'life1, 'async_trait>(
&'life0 self,
prefix: Option<&'life1 str>,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn search_by_tag<'life0, 'life1, 'async_trait>(
&'life0 self,
tag: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<MemoryEntry>, MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn set_tagged<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 str,
value: Value,
tags: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<(), MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Auto Trait Implementations§
impl !Freeze for SqliteMemoryStore
impl RefUnwindSafe for SqliteMemoryStore
impl Send for SqliteMemoryStore
impl Sync for SqliteMemoryStore
impl Unpin for SqliteMemoryStore
impl UnsafeUnpin for SqliteMemoryStore
impl UnwindSafe for SqliteMemoryStore
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