Interface ExceptionListener

  • All Known Implementing Classes:
    ExceptionListenerDispatcher, FBManagedConnection

    public interface ExceptionListener
    Listener for notifications of SQL Exceptions that occurred in the object listened on.

    The primary use case of this interface is to bridge the gap between the XCA managed connection or connection pools that need to detect fatal errors. In the implementation only the methods defined in the various Fb* interfaces in are required to notify the listeners.

    Listeners registered on a FbDatabase or FbService will also be notified of errors occurring in subordinate objects (eg statements).

    It is possible that a single exception is notified multiple times. Listeners should be prepared to handle this appropriately.

    Mark Rotteveel
    • Method Detail

      • errorOccurred

        void errorOccurred​(java.lang.Object source,
                           java.sql.SQLException ex)
        Notify about a SQLException
        source - The source of the event; note for caller: this should be the object this listener is registered at.
        ex - error that occurred.