|
Oracle Fusion Middleware Java API Reference for Oracle WebCenter Portal 11g Release 1 (11.1.1.6.0) E15995-05 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Cache<K,V>
A cache. Essentially this is just a named Map, however keys and values must be Serializable. A cache does not support null keys.
It is also assumed that the cache is managed in some way, so that old or expired entries are removed, etc. Therefore, a get operation is not guaranteed to return a value that was put - even one that was recently put, as the cache may be disabled, or that entry might have expired or been purged by the backing store of the cache.
Cache instances are obtained from the CacheFactory
. Caches obtained from the factory are singletons keyed by their name, so that two caches with the same name should represent the same cached values.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface java.util.Map |
---|
java.util.Map.Entry<K,V> |
Method Summary | |
---|---|
java.util.Set<java.util.Map.Entry<K,V>> |
entrySet() Returns a Set view of the mappings contained in this map. |
CacheConfig |
getCacheConfig() retrieve the configuration for this cache. |
java.util.Set<K> |
keySet() Returns a Set view of the keys contained in this cache. |
java.util.Collection<V> |
values() Returns a Collection view of the values contained in this cache. |
Methods inherited from interface java.util.Map |
---|
clear, containsKey, containsValue, equals, get, hashCode, isEmpty, put, putAll, remove, size |
Method Detail |
---|
CacheConfig getCacheConfig()
java.util.Set<K> keySet()
Set
view of the keys contained in this cache. Unlike the Map.keySet()
method, the set returned by this method might not be backed by the cache, so changes made to the set might not be reflected in the map (and vice-versa). Iterators obtained from this set therefore might not support removal of elements from the cache.keySet
in interface java.util.Map<K,V>
java.util.Collection<V> values()
Collection
view of the values contained in this cache. Unlike the Map.values()
method, the collection returned by this method might not be backed by the cache, so changes made to the collection might not be reflected in the map (and vice-versa). Iterators obtained from this collection therefore might not support removal of elements from the cache.values
in interface java.util.Map<K,V>
java.util.Set<java.util.Map.Entry<K,V>> entrySet()
Set
view of the mappings contained in this map. Unlike the Map.entrySet()
method, the set returned by this method might not be backed by the cache, so changes made to the set might not be reflected in the map (and vice-versa). Iterators obtained from this set therefore might not support removal of elements from the cache.entrySet
in interface java.util.Map<K,V>
|
Oracle Fusion Middleware Java API Reference for Oracle WebCenter Portal 11g Release 1 (11.1.1.6.0) E15995-05 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |