Package org.infinispan.notifications.cachelistener.event

Examples of org.infinispan.notifications.cachelistener.event.EventImpl


   @Override
   public void notifyCacheEntryPassivated(Object key, Object value, boolean pre, InvocationContext ctx) {
      if (!cacheEntryPassivatedListeners.isEmpty()) {
         InvocationContext contexts = icc.suspend();
         try {
            EventImpl e = new EventImpl();
            e.setCache(cache);
            e.setPre(pre);
            e.setKey(key);
            e.setValue(value);
            setTx(ctx, e);
            e.setType(CACHE_ENTRY_PASSIVATED);
            for (ListenerInvocation listener : cacheEntryPassivatedListeners) {
               listener.invoke(e);
            }
         } finally {
            icc.resume(contexts);
View Full Code Here


   public void notifyTransactionCompleted(GlobalTransaction transaction, boolean successful, InvocationContext ctx) {
      if (!transactionCompletedListeners.isEmpty()) {
         boolean isOriginLocal = ctx.isOriginLocal();
         InvocationContext contexts = icc.suspend();
         try {
            EventImpl e = new EventImpl();
            e.setCache(cache);
            e.setOriginLocal(isOriginLocal);
            e.setTransactionId(transaction);
            e.setTransactionSuccessful(successful);
            e.setType(TRANSACTION_COMPLETED);
            for (ListenerInvocation listener : transactionCompletedListeners) {
               listener.invoke(e);
            }
         } finally {
            icc.resume(contexts);
View Full Code Here

   public void notifyTransactionRegistered(GlobalTransaction globalTransaction, InvocationContext ctx) {
      if (!transactionRegisteredListeners.isEmpty()) {
         boolean isOriginLocal = ctx.isOriginLocal();
         InvocationContext contexts = icc.suspend();
         try {
            EventImpl e = new EventImpl();
            e.setCache(cache);
            e.setOriginLocal(isOriginLocal);
            e.setTransactionId(globalTransaction);
            e.setType(TRANSACTION_REGISTERED);
            for (ListenerInvocation listener : transactionRegisteredListeners) {
               listener.invoke(e);
            }
         } finally {
            icc.resume(contexts);
View Full Code Here

TOP

Related Classes of org.infinispan.notifications.cachelistener.event.EventImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.