Struct core_lib::cache::InMemCache
source · [−]pub struct InMemCache<K, V> { /* private fields */ }
Implementations
sourceimpl<K, V> InMemCache<K, V> where
K: Clone,
V: Clone,
impl<K, V> InMemCache<K, V> where
K: Clone,
V: Clone,
Trait Implementations
sourceimpl<K, V> Cache<K, V> for InMemCache<K, V> where
K: Eq + Hash + Sync + Send + Serialize,
V: Clone + Sync + Send,
impl<K, V> Cache<K, V> for InMemCache<K, V> where
K: Eq + Hash + Sync + Send + Serialize,
V: Clone + Sync + Send,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
k: &'life1 K
) -> Pin<Box<dyn Future<Output = Result<Option<V>, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn set<'life0, 'async_trait>(
&'life0 self,
k: K,
v: V
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
k: &'life1 K
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
sourceimpl<K: Clone, V: Clone> Clone for InMemCache<K, V>
impl<K: Clone, V: Clone> Clone for InMemCache<K, V>
sourcefn clone(&self) -> InMemCache<K, V>
fn clone(&self) -> InMemCache<K, V>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl<K, V> !RefUnwindSafe for InMemCache<K, V>
impl<K, V> Send for InMemCache<K, V> where
K: Send + Sync,
V: Send + Sync,
impl<K, V> Sync for InMemCache<K, V> where
K: Send + Sync,
V: Send + Sync,
impl<K, V> Unpin for InMemCache<K, V>
impl<K, V> !UnwindSafe for InMemCache<K, V>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more