|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jcs.auxiliary.AbstractAuxiliaryCache<K,V>
org.apache.jcs.auxiliary.AbstractAuxiliaryCacheEventLogging<K,V>
public abstract class AbstractAuxiliaryCacheEventLogging<K extends Serializable,V extends Serializable>
All ICacheEvents are defined as final. Children must implement process events. These are wrapped in event log parent calls.
You can override the public method, but if you don't, the default will call getWithTiming.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.apache.jcs.engine.behavior.ICacheType |
|---|
ICacheType.CacheType |
| Field Summary |
|---|
| Fields inherited from class org.apache.jcs.auxiliary.AbstractAuxiliaryCache |
|---|
cacheEventLogger, elementSerializer, keyMatcher |
| Constructor Summary | |
|---|---|
AbstractAuxiliaryCacheEventLogging()
|
|
| Method Summary | |
|---|---|
void |
dispose()
Synchronously dispose the remote cache; if failed, replace the remote handle with a zombie. |
protected void |
disposeWithEventLogging()
Synchronously dispose the remote cache; if failed, replace the remote handle with a zombie. |
ICacheElement<K,V> |
get(K key)
Gets the item from the cache. |
Map<K,ICacheElement<K,V>> |
getMatching(String pattern)
Gets items from the cache matching the given pattern. |
protected Map<K,ICacheElement<K,V>> |
getMatchingWithEventLogging(String pattern)
Gets mmatching items from the cache based on the given pattern. |
Map<K,ICacheElement<K,V>> |
getMultiple(Set<K> keys)
Gets multiple items from the cache based on the given set of keys. |
protected Map<K,ICacheElement<K,V>> |
getMultipleWithEventLogging(Set<K> keys)
Gets multiple items from the cache based on the given set of keys. |
protected ICacheElement<K,V> |
getWithEventLogging(K key)
Gets the item from the cache. |
protected abstract void |
processDispose()
Specific implementation of dispose. |
protected abstract ICacheElement<K,V> |
processGet(K key)
Implementation of get. |
protected abstract Map<K,ICacheElement<K,V>> |
processGetMatching(String pattern)
Implementation of getMatching. |
protected abstract Map<K,ICacheElement<K,V>> |
processGetMultiple(Set<K> keys)
Implementation of getMultiple. |
protected abstract boolean |
processRemove(K key)
Specific implementation of remove. |
protected abstract void |
processRemoveAll()
Specific implementation of removeAll. |
protected abstract void |
processUpdate(ICacheElement<K,V> cacheElement)
Implementation of put. |
boolean |
remove(K key)
Removes the item from the cache. |
void |
removeAll()
Removes all from the region. |
protected void |
removeAllWithEventLogging()
Removes all from the region. |
protected boolean |
removeWithEventLogging(K key)
Removes the item from the cache. |
void |
update(ICacheElement<K,V> cacheElement)
Puts an item into the cache. |
protected void |
updateWithEventLogging(ICacheElement<K,V> cacheElement)
Puts an item into the cache. |
| Methods inherited from class org.apache.jcs.auxiliary.AbstractAuxiliaryCache |
|---|
createICacheEvent, createICacheEvent, getCacheEventLogger, getElementSerializer, getEventLoggingExtraInfo, getKeyMatcher, logApplicationEvent, logError, logICacheEvent, setCacheEventLogger, setElementSerializer, setKeyMatcher |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.jcs.auxiliary.AuxiliaryCache |
|---|
getAuxiliaryCacheAttributes, getGroupKeys, getGroupNames, getStatistics |
| Methods inherited from interface org.apache.jcs.engine.behavior.ICache |
|---|
getCacheName, getSize, getStats, getStatus |
| Methods inherited from interface org.apache.jcs.engine.behavior.ICacheType |
|---|
getCacheType |
| Constructor Detail |
|---|
public AbstractAuxiliaryCacheEventLogging()
| Method Detail |
|---|
public void update(ICacheElement<K,V> cacheElement)
throws IOException
cacheElement -
IOException
protected final void updateWithEventLogging(ICacheElement<K,V> cacheElement)
throws IOException
cacheElement -
IOException
protected abstract void processUpdate(ICacheElement<K,V> cacheElement)
throws IOException
cacheElement -
IOException
public ICacheElement<K,V> get(K key)
throws IOException
key -
IOException
protected final ICacheElement<K,V> getWithEventLogging(K key)
throws IOException
key -
IOException
protected abstract ICacheElement<K,V> processGet(K key)
throws IOException
key -
IOException
public Map<K,ICacheElement<K,V>> getMultiple(Set<K> keys)
throws IOException
keys -
IOException
protected final Map<K,ICacheElement<K,V>> getMultipleWithEventLogging(Set<K> keys)
throws IOException
keys -
IOException
protected abstract Map<K,ICacheElement<K,V>> processGetMultiple(Set<K> keys)
throws IOException
keys -
IOException
public Map<K,ICacheElement<K,V>> getMatching(String pattern)
throws IOException
This only works with string keys. It's too expensive to do a toString on every key.
Auxiliaries will do their best to handle simple expressions. For instance, the JDBC disk cache will convert * to % and . to _
pattern -
IOException
protected final Map<K,ICacheElement<K,V>> getMatchingWithEventLogging(String pattern)
throws IOException
pattern -
IOException
protected abstract Map<K,ICacheElement<K,V>> processGetMatching(String pattern)
throws IOException
pattern -
IOException
public boolean remove(K key)
throws IOException
key -
IOException
protected final boolean removeWithEventLogging(K key)
throws IOException
key -
IOException
protected abstract boolean processRemove(K key)
throws IOException
key -
IOException
public void removeAll()
throws IOException
IOException
protected final void removeAllWithEventLogging()
throws IOException
IOException
protected abstract void processRemoveAll()
throws IOException
IOException
public void dispose()
throws IOException
IOException
protected final void disposeWithEventLogging()
throws IOException
IOException
protected abstract void processDispose()
throws IOException
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||