CacheEviction class
A class that handles cache eviction strategies.
Constructors
- CacheEviction.new(CacheAdapter _cacheAdapter, CacheAnalytics _analytics, {int? maxSize, int? maxItems, EvictionStrategy strategy = EvictionStrategy.lru})
- Creates a new instance of CacheEviction.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
checkAndEvict(
) → Future< bool> - Checks if the cache needs eviction and performs it if necessary.
-
evictByPriority(
) → Future< bool> - Evicts items based on priority, starting with the lowest priority.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited