Altair::Support::LRUCache(K, V)
Constructors
Instance methods
get(key : K) : V | Nil
Returns the cached value for key, moving it to the most-recently
used position, or nil when absent.
put(key : K, value : V) : Nil
Stores value under key, evicting the least-recently-used entry when the cache is at capacity. A zero capacity stores nothing, so a disabled cache degrades to a plain lookup.