com.arsdigita.persistence
Interface TransactionListener

All Known Implementing Classes:
AbstractTransactionListener

public interface TransactionListener

A simple listener to allow tasks to be performed after a transaction is committed or rolled back. A typical use of this listener would be handling repopulation of a data object cache (cf SiteNode). To prevent infinite recursion in the case where the listener itself uses a transaction, listener invocations are one time events - ie the listener is removed immediately after it has run.

Author:
Daniel Berrange
See Also:
TransactionContext

Method Summary
 void afterAbort(TransactionContext txn)
          Called immediately after the transaction has aborted
 void afterCommit(TransactionContext txn)
          Called immediately after the transaction has committed
 void beforeAbort(TransactionContext txn)
          Called immediately before the transaction has aborted
 void beforeCommit(TransactionContext txn)
          Called immediately before the transaction has committed
 

Method Detail

beforeCommit

public void beforeCommit(TransactionContext txn)
Called immediately before the transaction has committed


afterCommit

public void afterCommit(TransactionContext txn)
Called immediately after the transaction has committed


beforeAbort

public void beforeAbort(TransactionContext txn)
Called immediately before the transaction has aborted


afterAbort

public void afterAbort(TransactionContext txn)
Called immediately after the transaction has aborted



Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2337 UTC