pub struct CacheManager<E>where
E: AsyncExecutor,{ /* private fields */ }Implementations§
Source§impl<E> CacheManager<E>where
E: AsyncExecutor + 'static,
impl<E> CacheManager<E>where
E: AsyncExecutor + 'static,
pub fn new(async_executor: E, config: CacheManagerConfig) -> Self
pub fn register<I, T>(&mut self, input_validator: I, task_processor: T)where
I: InputValidator + 'static,
T: CacheTaskProcessor + 'static,
pub fn sender(&self) -> Sender<CacheTask>
pub fn start(&mut self)
pub fn init(&self, cache_id: &'static str) -> Result<(), ManualOperationError>
pub fn stop(&self, cache_id: &'static str) -> Result<(), ManualOperationError>
pub fn flush_all( &self, cache_id: &'static str, ) -> Result<(), ManualOperationError>
pub fn force_expiration<K>( &self, cache_id: &'static str, key: K, ) -> Result<(), ManualOperationError>
pub fn invalidate_with_properties<K, V>( &self, cache_id: &'static str, key: K, value: V, ) -> Result<(), ManualOperationError>
pub fn invalidate<K>( &self, expires_in: u64, cache_id: &'static str, key: K, ) -> Result<(), ManualOperationError>
pub fn cache_ids(&self) -> Iter<'_, &'static str>
pub fn statistics(&self) -> &Arc<CacheManagerStatistics>
Auto Trait Implementations§
impl<E> !RefUnwindSafe for CacheManager<E>
impl<E> !Sync for CacheManager<E>
impl<E> !UnwindSafe for CacheManager<E>
impl<E> Freeze for CacheManager<E>where
E: Freeze,
impl<E> Send for CacheManager<E>
impl<E> Unpin for CacheManager<E>
impl<E> UnsafeUnpin for CacheManager<E>where
E: UnsafeUnpin,
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