Class LRUMap<K,​V>

  • All Implemented Interfaces:
    Serializable, Cloneable, Map<K,​V>

    public class LRUMap<K,​V>
    extends LinkedHashMap<K,​V>
    An LRU cache, based on LinkedHashMap.

    This cache has a fixed maximum number of elements (cacheSize). If the cache is full and another entry is added, the LRU (least recently used) entry is dropped.

    Note: This class is not thread-safe.

    See Also:
    Serialized Form