|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.liferay.faces.util.cache.CacheWrapper<K,V>
public abstract class CacheWrapper<K,V>
| Constructor Summary | |
|---|---|
CacheWrapper()
|
|
| Method Summary | |
|---|---|
boolean |
containsKey(K key)
Returns true if the key (and therefor a corresponding value) is present in the cache or false otherwise. |
Set<K> |
getKeys()
Returns the set of all keys currently in the cache at the time this method was called. |
int |
getSize()
Returns the number of key-value pairs in the cache. |
V |
getValue(K key)
Returns the cached value that is mapped to this key or null if the value is not in the cache. |
V |
putValueIfAbsent(K key,
V value)
Puts the cached key-value pair into the cache if the key does not already exist in the cache. |
V |
removeValue(K key)
Removes an entry from the cache. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.faces.FacesWrapper |
|---|
getWrapped |
| Constructor Detail |
|---|
public CacheWrapper()
| Method Detail |
|---|
public boolean containsKey(K key)
Cache
containsKey in interface Cache<K,V>key - The key that the value is mapped to.Cache.containsKey(java.lang.Object)public Set<K> getKeys()
Cache
getKeys in interface Cache<K,V>Cache.getKeys()public int getSize()
Cache
getSize in interface Cache<K,V>Cache.getSize()public V getValue(K key)
Cache
getValue in interface Cache<K,V>key - The key that the value is mapped to.Cache.getValue(java.lang.Object)
public V putValueIfAbsent(K key,
V value)
Cache
putValueIfAbsent in interface Cache<K,V>key - The key that the value is mapped to.value - The value to be cached.Cache.putValueIfAbsent(java.lang.Object, java.lang.Object)public V removeValue(K key)
Cache
removeValue in interface Cache<K,V>key - The key that the value is mapped to.Cache.removeValue(java.lang.Object)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||