Interface ICacheListener<K,V> 
- All Known Subinterfaces:
- ILateralCacheListener<K,,- V> - IRemoteCacheListener<K,- V> 
- All Known Implementing Classes:
- AbstractDiskCache.MyCacheListener,- AbstractRemoteCacheListener,- CacheAdaptor,- LateralTCPListener,- RemoteCacheListener,- RemoteHttpClientListener
public interface ICacheListener<K,V> 
Used to receive a cache event notification.
 
Note: objects which implement this interface are local listeners to cache changes, whereas objects which implement IRmiCacheListener are remote listeners to cache changes.
- 
Method SummaryModifier and TypeMethodDescriptionlongGets the listenerId attribute of the ICacheListener objectvoidhandleDispose(String cacheName) Notifies the subscribers for freeing up the named cache.voidhandlePut(ICacheElement<K, V> item) Notifies the subscribers for a cache entry update.voidhandleRemove(String cacheName, K key) Notifies the subscribers for a cache entry removal.voidhandleRemoveAll(String cacheName) Notifies the subscribers for a cache remove-all.voidsetListenerId(long id) sets unique identifier of listener home
- 
Method Details- 
handlePutNotifies the subscribers for a cache entry update.- Parameters:
- item-
- Throws:
- IOException
 
- 
handleRemoveNotifies the subscribers for a cache entry removal.- Parameters:
- cacheName-
- key-
- Throws:
- IOException
 
- 
handleRemoveAllNotifies the subscribers for a cache remove-all.- Parameters:
- cacheName-
- Throws:
- IOException
 
- 
handleDisposeNotifies the subscribers for freeing up the named cache.- Parameters:
- cacheName-
- Throws:
- IOException
 
- 
setListenerIdsets unique identifier of listener home- Parameters:
- id- The new listenerId value
- Throws:
- IOException
 
- 
getListenerIdGets the listenerId attribute of the ICacheListener object- Returns:
- The listenerId value
- Throws:
- IOException
 
 
-