Interface CacheNotifier<K,V>
-
- All Superinterfaces:
ClassLoaderAwareFilteringListenable<K,V>
,ClassLoaderAwareListenable
,DataConversionAwareListenable<K,V>
,FilteringListenable<K,V>
,Listenable
- All Known Subinterfaces:
ClusterCacheNotifier<K,V>
- All Known Implementing Classes:
CacheNotifierImpl
public interface CacheNotifier<K,V> extends DataConversionAwareListenable<K,V>, ClassLoaderAwareListenable
Public interface with all allowed notifications.- Since:
- 4.0
- Author:
- Mircea.Markus@jboss.com
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
notifyCacheEntriesEvicted(Collection<InternalCacheEntry<? extends K,? extends V>> entries, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntriesEvictedEvent
event.void
notifyCacheEntryActivated(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryActivatedEvent
event.void
notifyCacheEntryCreated(K key, V value, Metadata metadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryCreatedEvent
event.void
notifyCacheEntryExpired(K key, V value, Metadata metadata, InvocationContext ctx)
Notifies all registered listeners of a CacheEntryExpired event.void
notifyCacheEntryInvalidated(K key, V value, Metadata metadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryInvalidatedEvent
event.void
notifyCacheEntryLoaded(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryLoadedEvent
event.void
notifyCacheEntryModified(K key, V value, Metadata metadata, V previousValue, Metadata previousMetadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryModifiedEvent
event.void
notifyCacheEntryPassivated(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryPassivatedEvent
event.void
notifyCacheEntryRemoved(K key, V previousValue, Metadata previousMetadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryRemovedEvent
event.void
notifyCacheEntryVisited(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryVisitedEvent
event.void
notifyDataRehashed(ConsistentHash oldCH, ConsistentHash newCH, ConsistentHash unionCH, int newTopologyId, boolean pre)
void
notifyPartitionStatusChanged(AvailabilityMode mode, boolean pre)
void
notifyPersistenceAvailabilityChanged(boolean available)
void
notifyTopologyChanged(CacheTopology oldTopology, CacheTopology newTopology, int newTopologyId, boolean pre)
void
notifyTransactionCompleted(GlobalTransaction transaction, boolean successful, InvocationContext ctx)
Notifies all registered listeners of a transaction completion event.void
notifyTransactionRegistered(GlobalTransaction globalTransaction, boolean isOriginLocal)
Notifies all registered listeners of a transaction registration event.-
Methods inherited from interface org.infinispan.notifications.ClassLoaderAwareFilteringListenable
addListener, addListener
-
Methods inherited from interface org.infinispan.notifications.ClassLoaderAwareListenable
addListener
-
Methods inherited from interface org.infinispan.notifications.DataConversionAwareListenable
addFilteredListener, addListener, addListener
-
Methods inherited from interface org.infinispan.notifications.FilteringListenable
addFilteredListener, addListener, addListener, addStorageFormatFilteredListener
-
Methods inherited from interface org.infinispan.notifications.Listenable
addListener, getListeners, removeListener
-
-
-
-
Method Detail
-
notifyCacheEntryCreated
void notifyCacheEntryCreated(K key, V value, Metadata metadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryCreatedEvent
event.
-
notifyCacheEntryModified
void notifyCacheEntryModified(K key, V value, Metadata metadata, V previousValue, Metadata previousMetadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryModifiedEvent
event.
-
notifyCacheEntryRemoved
void notifyCacheEntryRemoved(K key, V previousValue, Metadata previousMetadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryRemovedEvent
event.
-
notifyCacheEntryVisited
void notifyCacheEntryVisited(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryVisitedEvent
event.
-
notifyCacheEntriesEvicted
void notifyCacheEntriesEvicted(Collection<InternalCacheEntry<? extends K,? extends V>> entries, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntriesEvictedEvent
event.
-
notifyCacheEntryExpired
void notifyCacheEntryExpired(K key, V value, Metadata metadata, InvocationContext ctx)
Notifies all registered listeners of a CacheEntryExpired event.
-
notifyCacheEntryInvalidated
void notifyCacheEntryInvalidated(K key, V value, Metadata metadata, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryInvalidatedEvent
event.
-
notifyCacheEntryLoaded
void notifyCacheEntryLoaded(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryLoadedEvent
event.
-
notifyCacheEntryActivated
void notifyCacheEntryActivated(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryActivatedEvent
event.
-
notifyCacheEntryPassivated
void notifyCacheEntryPassivated(K key, V value, boolean pre, InvocationContext ctx, org.infinispan.commands.FlagAffectedCommand command)
Notifies all registered listeners of aCacheEntryPassivatedEvent
event.
-
notifyTransactionCompleted
void notifyTransactionCompleted(GlobalTransaction transaction, boolean successful, InvocationContext ctx)
Notifies all registered listeners of a transaction completion event.- Parameters:
transaction
- the transaction that has just completedsuccessful
- if true, the transaction committed. If false, this is a rollback event
-
notifyTransactionRegistered
void notifyTransactionRegistered(GlobalTransaction globalTransaction, boolean isOriginLocal)
Notifies all registered listeners of a transaction registration event.- Parameters:
globalTransaction
-
-
notifyDataRehashed
void notifyDataRehashed(ConsistentHash oldCH, ConsistentHash newCH, ConsistentHash unionCH, int newTopologyId, boolean pre)
-
notifyTopologyChanged
void notifyTopologyChanged(CacheTopology oldTopology, CacheTopology newTopology, int newTopologyId, boolean pre)
-
notifyPartitionStatusChanged
void notifyPartitionStatusChanged(AvailabilityMode mode, boolean pre)
-
notifyPersistenceAvailabilityChanged
void notifyPersistenceAvailabilityChanged(boolean available)
-
-