TransactionContextListener (Apache Tomcat 10.1.48 API Documentation)
Description: declaration: package: org.apache.tomcat.dbcp.dbcp2.managed, interface: TransactionContextListener

# Interface TransactionContextListener

All Known Implementing Classes:
  `ManagedConnection.CompletionListener`

public interface TransactionContextListener
A listener for transaction completion events.

Since:
  2.0

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `afterCompletion(TransactionContext transactionContext, boolean committed)`
  Called after a transaction commits or rolls back.

- ## Method Details

  - ### afterCompletion

    void afterCompletion(TransactionContext transactionContext, boolean committed)
    Called after a transaction commits or rolls back.
    Parameters:
      `transactionContext` - the transaction context that completed.
      `committed` - true if the transaction committed; false otherwise.