|
GemFire 5.7.1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.gemstone.gemfire.cache.util.CacheListenerAdapter
public abstract class CacheListenerAdapter
Utility class that implements all methods in CacheListener
with empty implementations. Applications can subclass this class and only
override the methods for the events of interest.
| Constructor Summary | |
|---|---|
CacheListenerAdapter()
|
|
| Method Summary | |
|---|---|
void |
afterCreate(EntryEvent event)
Handles the event of new key being added to a region. |
void |
afterDestroy(EntryEvent event)
Handles the event of an entry being destroyed. |
void |
afterInvalidate(EntryEvent event)
Handles the event of an entry's value being invalidated. |
void |
afterRegionClear(RegionEvent event)
Handles the event of a region being cleared. |
void |
afterRegionCreate(RegionEvent event)
Handles the event of a region being created. |
void |
afterRegionDestroy(RegionEvent event)
Handles the event of a region being destroyed. |
void |
afterRegionInvalidate(RegionEvent event)
Handles the event of a region being invalidated. |
void |
afterRegionLive(RegionEvent event)
Handles the event of a region being live after receiving the marker from the server. |
void |
afterUpdate(EntryEvent event)
Handles the event of an entry's value being modified in a region. |
void |
close()
Called when the region containing this callback is closed or destroyed, when the cache is closed, or when a callback is removed from a region using an AttributesMutator. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CacheListenerAdapter()
| Method Detail |
|---|
public void afterCreate(EntryEvent event)
CacheListener
afterCreate in interface CacheListenerevent - the EntryEventRegion.create(Object, Object),
Region.put(Object, Object),
Region.get(Object)public void afterDestroy(EntryEvent event)
CacheListener
afterDestroy in interface CacheListenerevent - the EntryEventRegion.destroy(Object)public void afterInvalidate(EntryEvent event)
CacheListener
afterInvalidate in interface CacheListenerevent - the EntryEventRegion.invalidate(Object)public void afterRegionDestroy(RegionEvent event)
CacheListenerafterRegionDestroyed event invoked on its listener.
afterRegionDestroy in interface CacheListenerevent - the RegionEventRegion.destroyRegion(),
Region.localDestroyRegion(),
Region.close(),
Cache.close()public void afterRegionCreate(RegionEvent event)
CacheListenerNote that this method is only called
for creates done in the local vm. To be notified of creates done in remote
vms use RegionMembershipListener.afterRemoteRegionCreate(com.gemstone.gemfire.cache.RegionEvent).
afterRegionCreate in interface CacheListenerevent - the RegionEventCache.createRegion(java.lang.String, com.gemstone.gemfire.cache.RegionAttributes),
Region.createSubregion(java.lang.String, com.gemstone.gemfire.cache.RegionAttributes)public void afterRegionInvalidate(RegionEvent event)
CacheListenerregionInvalidated event invoked on its listener.
afterRegionInvalidate in interface CacheListenerevent - the RegionEventRegion.invalidateRegion(),
Region.localInvalidateRegion()public void afterUpdate(EntryEvent event)
CacheListener
afterUpdate in interface CacheListenerevent - the EntryEventRegion.put(Object, Object)public void afterRegionClear(RegionEvent event)
CacheListener
afterRegionClear in interface CacheListenerevent - the RegionEventRegion.clear()public void afterRegionLive(RegionEvent event)
CacheListener
afterRegionLive in interface CacheListenerevent - the RegionEventCache.readyForEvents()public void close()
CacheCallbackAttributesMutator.
Implementations should cleanup any external resources such as database connections. Any runtime exceptions this method throws will be logged.
It is possible for this method to be called multiple times on a single callback instance, so implementations must be tolerant of this.
close in interface CacheCallbackCache.close(),
Region.close(),
Region.localDestroyRegion(),
Region.destroyRegion(),
AttributesMutator
|
GemFire 5.7.1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||