org.apache.commons.dbcp2.managed

## Class ManagedConnection.CompletionListener

- java.lang.Object
- - org.apache.commons.dbcp2.managed.ManagedConnection.CompletionListener

- All Implemented Interfaces:
    TransactionContextListener
  Enclosing class:
    ManagedConnection<C extends Connection>

      protected class ManagedConnection.CompletionListener
      extends Object
      implements TransactionContextListener

  Delegates to `ManagedConnection.transactionComplete()` for transaction completion events.
  Since:
    2.0

- - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `CompletionListener()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `afterCompletion(TransactionContext completedContext, boolean committed)` Occurs after the transaction commits or rolls back.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### CompletionListener

          protected CompletionListener()

  - ### Method Detail

    - #### afterCompletion

          public void afterCompletion(TransactionContext completedContext,
                                      boolean committed)

      Description copied from interface: `TransactionContextListener`
      Occurs after the transaction commits or rolls back.
      Specified by:
        `afterCompletion` in interface `TransactionContextListener`
      Parameters:
        `completedContext` - the transaction context that completed
        `committed` - true if the transaction committed; false otherwise

Copyright © 2001–2019 The Apache Software Foundation. All rights reserved.