org.wamblee.test.transactions
Interface TransactionResource<T>

Type Parameters:
T -
All Known Implementing Classes:
JpaBuilder

public interface TransactionResource<T>

Interfaces to be implemented by resources that want to participate in transactions managed through SimpleTransactionManager.

Author:
Erik Brakkee

Method Summary
 T begin()
          Begins a transaction.
 void commit(T aT)
          Commits the transaction.
 void rollback(T aT)
          Rolls back a transaction.
 

Method Detail

begin

T begin()
Begins a transaction.

Returns:
Object that manages the transaction for the resource.

rollback

void rollback(T aT)
Rolls back a transaction.

Parameters:
aT - Object that manages the transaction for the resource.

commit

void commit(T aT)
Commits the transaction.

Parameters:
aT - Object that manages the transaction for the resource.


Copyright © 2010. All Rights Reserved.