Interface CacheMap<K,V>

All Superinterfaces:
Map<K,V>
All Known Subinterfaces:
YFIFOMap<K,V>
All Known Implementing Classes:
AbstractBaseCacheMap, AbstractCacheMap, BaseCacheYFastFIFOMap, BaseCacheYFastFIFOMapStub, YFastFIFOMap

public interface CacheMap<K,V> extends Map<K,V>
  • Method Details

    • clear

      void clear()
      Specified by:
      clear in interface Map<K,V>
    • size

      int size()
      the current size of the cache map
      Specified by:
      size in interface Map<K,V>
    • maxSize

      int maxSize()
      The maximum allowed size of the map
    • getMaxReachedSize

      int getMaxReachedSize()
      The maximum size since initialization/creation
      Returns:
      the maximum size since initialization
    • processDisplacedEntry

      void processDisplacedEntry(K key, V value)
      do something before a entry is displaced because the map is growing to big (if an entry is added and size() is getting bigger as maxSize()), this method will be called before an old entry is being removed