|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.metamatrix.cache.jboss.JBossCache<K,V>
public class JBossCache<K,V>
Implementation of Cache using JBoss Cache
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.metamatrix.cache.Cache |
|---|
Cache.Type |
| Constructor Summary | |
|---|---|
JBossCache(org.jboss.cache.Cache cacheStore,
org.jboss.cache.Fqn fqn)
|
|
| Method Summary | |
|---|---|
Cache |
addChild(java.lang.String name)
Add a child node to the current cache node |
void |
addListener(CacheListener listener)
Listener to get the updates on this Cache |
void |
clear()
Removes all the keys and their values from the Cache |
V |
get(K key)
Retrieves the value for the given Key |
Cache |
getChild(java.lang.String name)
Get the child cache node from the current node |
java.util.List<Cache> |
getChildren()
Get child nodes under this cache node. |
java.util.Set<K> |
keySet()
Returns a Set containing the data in this Cache |
V |
put(K key,
V value)
Associates the specified value with the specified key this cache. |
V |
remove(K key)
Removes the value for this key from a Cache. |
boolean |
removeChild(java.lang.String name)
Destroys the child from the current node; no-op if node not found |
void |
removeListener()
Remove Listener to stop the updates on this Cache |
int |
size()
Size of the cache |
java.util.Collection<V> |
values()
Returns a Collection containing the data in this Cache |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JBossCache(org.jboss.cache.Cache cacheStore,
org.jboss.cache.Fqn fqn)
| Method Detail |
|---|
public V get(K key)
get in interface Cache<K,V>key - key under which value is to be retrieved.
public V put(K key,
V value)
put in interface Cache<K,V>key - key with which the specified value is to be associated.value - value to be associated with the specified key.
null if there was no mapping for key.
A null return can also indicate that the key previously associated null with the specified key,
if the implementation supports null values.public V remove(K key)
null if the Key contained no mapping.
remove in interface Cache<K,V>key - key whose mapping is to be removed
public java.util.Set<K> keySet()
Set containing the data in this Cache
keySet in interface Cache<K,V>Set containing the data in this Cache. If there is no data,
an empty Set is returned. The Set returned is always immutable.public int size()
size in interface Cache<K,V>public void clear()
clear in interface Cache<K,V>public java.util.Collection<V> values()
CacheCollection containing the data in this Cache
values in interface Cache<K,V>Collection containing the data in this Cache. If there is no data,
an empty Collection is returned.public void addListener(CacheListener listener)
addListener in interface Cache<K,V>public void removeListener()
removeListener in interface Cache<K,V>public Cache addChild(java.lang.String name)
addChild in interface Cache<K,V>name - - name of the child
public Cache getChild(java.lang.String name)
getChild in interface Cache<K,V>public java.util.List<Cache> getChildren()
getChildren in interface Cache<K,V>public boolean removeChild(java.lang.String name)
removeChild in interface Cache<K,V>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||