Package javax.resource.spi

Examples of javax.resource.spi.ConnectionEventListener


      {
         copy = new ArrayList(listeners);
      }
      for (Iterator i = copy.iterator(); i.hasNext(); )
      {
         ConnectionEventListener cel = (ConnectionEventListener)i.next();
         try
         {
            cel.connectionErrorOccurred(ce);
         }
         catch (Throwable t)
         {
         }
      }
View Full Code Here


      ConnectionEvent ce = new ConnectionEvent(this, ConnectionEvent.CONNECTION_ERROR_OCCURRED, e);
      ce.setConnectionHandle(handle);
      Collection copy = new ArrayList(listeners);
      for (Iterator i = copy.iterator(); i.hasNext(); )
      {
         ConnectionEventListener cel = (ConnectionEventListener)i.next();
         try
         {
            cel.connectionErrorOccurred(ce);
         }
         catch (Throwable ignored)
         {
         }
      }
View Full Code Here

   protected void fireConnectionEvent(ConnectionEvent evt)
   {
      for(int i=listeners.size()-1; i >= 0; i--)
      {
         ConnectionEventListener listener = (ConnectionEventListener) listeners.get(i);
         if(evt.getId() == ConnectionEvent.CONNECTION_CLOSED)
            listener.connectionClosed(evt);
         else if(evt.getId() == ConnectionEvent.CONNECTION_ERROR_OCCURRED)
            listener.connectionErrorOccurred(evt);
      }
   }
View Full Code Here

        ConnectionEvent event = new ConnectionEvent(MuleManagedConnection.this,
            ConnectionEvent.LOCAL_TRANSACTION_STARTED);
        Iterator iterator = listeners.iterator();
        while (iterator.hasNext())
        {
            ConnectionEventListener l = (ConnectionEventListener)iterator.next();
            l.localTransactionStarted(event);
        }
    }
View Full Code Here

        ConnectionEvent event = new ConnectionEvent(MuleManagedConnection.this,
            ConnectionEvent.LOCAL_TRANSACTION_COMMITTED);
        Iterator iterator = listeners.iterator();
        while (iterator.hasNext())
        {
            ConnectionEventListener l = (ConnectionEventListener)iterator.next();
            l.localTransactionCommitted(event);
        }
    }
View Full Code Here

        ConnectionEvent event = new ConnectionEvent(MuleManagedConnection.this,
            ConnectionEvent.LOCAL_TRANSACTION_ROLLEDBACK);
        Iterator iterator = listeners.iterator();
        while (iterator.hasNext())
        {
            ConnectionEventListener l = (ConnectionEventListener)iterator.next();
            l.localTransactionRolledback(event);
        }
    }
View Full Code Here

        event.setConnectionHandle(connection);

        Iterator iterator = listeners.iterator();
        while (iterator.hasNext())
        {
            ConnectionEventListener l = (ConnectionEventListener)iterator.next();
            l.connectionClosed(event);
        }
    }
View Full Code Here

        ConnectionEvent event = new ConnectionEvent(MuleManagedConnection.this,
            ConnectionEvent.CONNECTION_ERROR_OCCURRED, error);
        Iterator iterator = listeners.iterator();
        while (iterator.hasNext())
        {
            ConnectionEventListener l = (ConnectionEventListener)iterator.next();
            l.connectionErrorOccurred(event);
        }
    }
View Full Code Here

    private void fireBeginEvent() {
        ConnectionEvent event = new ConnectionEvent(ActiveMQManagedConnection.this,
                ConnectionEvent.LOCAL_TRANSACTION_STARTED);
        Iterator iterator = listeners.iterator();
        while (iterator.hasNext()) {
            ConnectionEventListener l = (ConnectionEventListener) iterator.next();
            l.localTransactionStarted(event);
        }
    }
View Full Code Here

    private void fireCommitEvent() {
        ConnectionEvent event = new ConnectionEvent(ActiveMQManagedConnection.this,
                ConnectionEvent.LOCAL_TRANSACTION_COMMITTED);
        Iterator iterator = listeners.iterator();
        while (iterator.hasNext()) {
            ConnectionEventListener l = (ConnectionEventListener) iterator.next();
            l.localTransactionCommitted(event);
        }
    }
View Full Code Here

TOP

Related Classes of javax.resource.spi.ConnectionEventListener

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.