pub struct IntelligentCache<T>{ /* private fields */ }Expand description
Intelligent cache with TTL and LRU eviction
Implementations§
Source§impl<T> IntelligentCache<T>
impl<T> IntelligentCache<T>
pub fn new(config: CacheConfig) -> Self
Sourcepub async fn cleanup_expired(&self)
pub async fn cleanup_expired(&self)
Clear expired entries
Sourcepub async fn get_metrics(&self) -> CacheMetrics
pub async fn get_metrics(&self) -> CacheMetrics
Get cache metrics
Auto Trait Implementations§
impl<T> Freeze for IntelligentCache<T>
impl<T> !RefUnwindSafe for IntelligentCache<T>
impl<T> Send for IntelligentCache<T>
impl<T> Sync for IntelligentCache<T>
impl<T> Unpin for IntelligentCache<T>
impl<T> !UnwindSafe for IntelligentCache<T>
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