public abstract class DatabaseConnectionsListener extends java.lang.Object implements ConnectionsListener, DisconnectListener
The listener methods are not abstract, so a subclass can override just the methods they are interested in.
DatabaseConnections| Modifier and Type | Class and Description |
|---|---|
static class |
DatabaseConnectionsListener.ConnectionType
Used to distinguish types of "connection connected" events for any Connection created through the API.
|
| Constructor and Description |
|---|
DatabaseConnectionsListener() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canDisconnect(ConnectionsEvent event)
This allows a listener to veto a disconnect by returning false.
|
void |
connectionAdded(ConnectionsEvent event)
Called when a connection has been added.
|
void |
connectionConnected(ConnectionsEvent event, DatabaseConnectionsListener.ConnectionType type)
This is called when a connection definition is successfully used to create a Connection to the database.
|
void |
connectionDisconnected(ConnectionsEvent event)
This is called on all listeners after a successful disconnect of the connection.
|
void |
connectionRemoved(ConnectionsEvent event)
Called when a connection has been removed.
|
void |
connectionUpdated(ConnectionsEvent event)
Called when a connection has been updated.
|
public void connectionAdded(ConnectionsEvent event)
ConnectionsListenerconnectionAdded in interface ConnectionsListenerpublic void connectionRemoved(ConnectionsEvent event)
ConnectionsListenerconnectionRemoved in interface ConnectionsListenerpublic void connectionUpdated(ConnectionsEvent event)
ConnectionsListenerconnectionUpdated in interface ConnectionsListenerpublic boolean canDisconnect(ConnectionsEvent event)
DisconnectListenercanDisconnect in interface DisconnectListenerevent - the connection event describing the connection to be disconnected.public void connectionDisconnected(ConnectionsEvent event)
DisconnectListenerconnectionDisconnected in interface DisconnectListenerevent - the connection event describing the connection that has been disconnected.public void connectionConnected(ConnectionsEvent event, DatabaseConnectionsListener.ConnectionType type)
event - the event describing the connection that has been connected.