Previous Topic Next topic Print topic


Class CobolConnectionEventListener

The connector architecture provides an event callback mechanism that enables an application server to receive notifications from a ManagedConnection instance. The App server implements this class in order to listen to event notifications from ManagedConnection instance.
java.lang.Object

extended bycom.microfocus.cobol.connector.spi.CobolConnectionEventListener

Class Specifications

public class CobolConnectionEventListener

extends Object

implements ConnectionEventListener, Serializable

See Also:

Serialized Form

Constructor Summary

CobolConnectionEventListener(ManagedConnection mcon)
Create a connection event listener.

Methods

Method Summary
protected void sendEvent int eventType, Exception ex, Object connectionHandle

Send the event to all listeners of the connectionEvent.

protected void addConnectorListener (ConnectionEventListener l)

Add a connection listener to the list of listeners.

protected void removeConnectorListener(ConnectionEventListener l)

Remove a connection listener to the list of listeners.

void connectionClosed (equals event)

Send a connection closed event.

void connectionErrorOccurred(equals event)

Send a connection error occurred event.

void localTransactionCommitted(equals event)

Send a local transaction committed event.

void localTransactionRolledBack(equals event)

Send a local transaction rolled back event.

void localTransactionStarted(equals event)

Send a local transaction started event.

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

CobolConnectionEventListener
public CobolConnectionEventListener(ManagedConnection mcon)

Create a connection event listener.

Parameters:
mcon CobolManagedConnection instance

Method Detail

sendEvent
protected void sendEvent(int eventType,
                         Exception ex,
                         Object connectionHandle)

Send the event to all listeners of the connectionEvent.

Parameters:
eventType The event type.
ex The exception to be associated with Connection event.
connectionHandle The connection handle to be associated with Connection event.
addConnectorListener
protected void addConnectorListener(ConnectionEventListener l)

Add a connection listener to the list of listeners.

Parameters:
1 The connection listener.
removeConnectorListener
protected void removeConnectorListener(ConnectionEventListener l)

Remove a connection listener to the list of listeners.

Parameters:
1 The connection listener.
connectionClosed
void connectionClosed(equals event)

Send a connection closed event.

Specified by:
connectionClosed in interface ConnectionEventListener
Parameters:
event The connection event.
connectionErrorOccurred
void connectionErrorOccurred(equals event)

Send a connection error occurred event.

Specified by:
connectionErrorOccurred in interface ConnectionEventListener
Parameters:
event The connection event.
localTransactionCommitted
void localTransactionCommitted(equals event)

Send a local transaction committed event.

Specified by:
localTransactionCommitted in interface ConnectionEventListener
Parameters:
event The connection event.
localTransactionRolledBack
void localTransactionRolledBack(equals event)

Send a local transaction rolled back event.

Specified by:
localTransactionRolledBack in interface ConnectionEventListener
Parameters:
event The connection event.
localTransactionStarted
void localTransactionStarted(equals event)

Send a local transaction started event.

Specified by:
localTransactionStarted in interface ConnectionEventListener
Parameters:
event The connection event.
Previous Topic Next topic Print topic