Class TestCache<K,V>
- java.lang.Object
-
- org.thymeleaf.testing.templateengine.engine.cache.TestCache<K,V>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()Clear the entire cache.voidclearKey(K key)Clears a specific entry in the cache.Vget(K key)Retrieve a value from the cache.Vget(K key, ICacheEntryValidityChecker<? super K,? super V> validityChecker)Retrieve a value from the cache, using the specified validity checker to ensure the entry is still valid.java.util.Set<K>keySet()Returns all the keys contained in this cache.private java.lang.Objectprefix(K key)voidput(K key, V value)Insert a new value into the cache.
-
-
-
Method Detail
-
prefix
private java.lang.Object prefix(K key)
-
put
public void put(K key, V value)
Description copied from interface:ICacheInsert a new value into the cache.
-
get
public V get(K key, ICacheEntryValidityChecker<? super K,? super V> validityChecker)
Description copied from interface:ICacheRetrieve a value from the cache, using the specified validity checker to ensure the entry is still valid. If the cache already has a default validity checker, this method should override this setting and use the one specified instead.
-
clear
public void clear()
Description copied from interface:ICacheClear the entire cache.
-
clearKey
public void clearKey(K key)
Description copied from interface:ICacheClears a specific entry in the cache.
-
keySet
public java.util.Set<K> keySet()
Description copied from interface:ICacheReturns all the keys contained in this cache. Note this method might return keys for entries that are already invalid, so the result of calling
ICache.get(Object)for these keys might benull.
-
-