CacheManager class

A simple in-memory cache manager for storing expanded URLs and location data.

This class provides basic caching functionality to avoid redundant network requests for the same URLs. The cache has a maximum size limit and uses a simple LRU (Least Recently Used) eviction policy.

Constructors

CacheManager()
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
size int
Returns the current cache size.
no setter

Methods

clear() → void
Clears all entries from the cache.
containsKey(String key) bool
Checks if a key exists in the cache and is not expired.
get(String key) → dynamic
Retrieves a value from the cache.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
put(String key, dynamic value, {int expirationMinutes = 60}) → void
Stores a value in the cache with an optional expiration time.
remove(String key) → void
Removes a specific key from the cache.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited