@CacheListener public class ViewChangeListener { private Vector<Address> oldMembers; @ViewChanged public void handleViewChange(ViewChangedEvent event) { View newView = event.getNewView(); if (trace) log.trace("BuddyManager CacheListener - got view change with new view " + newView); Vector<Address> newMembers = newView.getMembers(); // the whole 'oldMembers' concept is only used for buddy pool announcements. MembershipChange mc = new MembershipChange(oldMembers == null ? null : new Vector<Address>(oldMembers), new Vector<Address>(newMembers)); enqueueViewChange(mc); if (oldMembers == null) oldMembers = new Vector<Address>(); oldMembers.clear(); oldMembers.addAll(newMembers); } }
/** * Tests if a class is properly annotated as a CacheListener and returns whether callbacks on this class should be invoked * synchronously or asynchronously. * * @param listenerClass class to inspect * @return true if callbacks on this class should use the syncProcessor; false if it should use the asyncProcessor. */ private static boolean testListenerClassValidity(Class<?> listenerClass) { CacheListener cl = listenerClass.getAnnotation(CacheListener.class); if (cl == null) throw new IncorrectCacheListenerException("Cache listener class MUST be annotated with org.jboss.cache.notifications.annotation.CacheListener"); if (!Modifier.isPublic(listenerClass.getModifiers())) throw new IncorrectCacheListenerException("Cache listener class MUST be public!"); return cl.sync(); }
@CacheListener public class CollectionRegionImpl extends TransactionalDataRegionAdapter implements CollectionRegion {
@CacheListener public class EntityRegionImpl extends TransactionalDataRegionAdapter implements EntityRegion {
@CacheListener public class SingletonStoreListener
@org.jboss.cache.notifications.annotation.CacheListener public class SipPassivationListener extends CacheListenerBase
@org.jboss.cache.notifications.annotation.CacheListener public class JBossJainSipCacheListener { private static StackLogger clusteredlogger = CommonLogger.getLogger(JBossJainSipCacheListener.class);
@CacheListener public class QueryResultsRegionImpl extends TransactionalDataRegionAdapter implements QueryResultsRegion {
@CacheListener public class TimestampsRegionImpl extends TransactionalDataRegionAdapter implements TimestampsRegion {
@CacheListener public class TimestampsRegionImpl extends TransactionalDataRegionAdapter implements TimestampsRegion {
@CacheListener public class CacheNotificationListener
@CacheListener public class ConsoleListener
@CacheListener public class ClusteredConcurrentTimestampsRegionImpl extends TransactionalDataRegionAdapter implements TimestampsRegion {
@CacheListener public class ClusteredConcurrentTimestampsRegionImpl extends TransactionalDataRegionAdapter implements TimestampsRegion {
@CacheListener public abstract class BasicRegionAdapter implements Region {
@org.jboss.cache.notifications.annotation.CacheListener(sync=false) public class SipCacheListener extends CacheListenerBase