put method
dynamic
put(
- K key,
- V value
Implementation
put(K key, V value) {
if (cachedElements.length == maxSize) {
_invalidateOldestValue();
}
cachedElements.update(key, (v) => CachedElement(value, DateTime.now()), ifAbsent: () => CachedElement(value, DateTime.now()));
}