java.lang.Object
com.foursoft.harness.navext.runtime.cache.SimpleCache<K,V>
Type Parameters:
K - The type of the key
V - The type of the value

public class SimpleCache<K,V> extends Object
Simple Cache, loading the value for a key via a CacheLoader. Caching the results in a HashMap. For each key, the CacheLoader is only called once.
Author:
becker
  • Constructor Details

  • Method Details

    • get

      public V get(K key)
      get the value for a given key
      Parameters:
      key - the key
      Returns:
      the value, maybe Null
    • getAllLoadedValues

      public Collection<V> getAllLoadedValues()
      All loaded values that are currently initialized in this cache.
      Returns:
      returning all values of the cache