com.pentagaia.tb.tx
Interface ITransactionManager

All Known Subinterfaces:
ITransactionService
All Known Implementing Classes:
TransactionManager, TransactionService

public interface ITransactionManager

Interface to access pds transactions.

Since:
0.1.0
Version:
0.1.0
Author:
mepeisen

Method Summary
 void addTransactionListener(ITransactionListener listener)
          Adds a transaction listener
 ITransaction begin(boolean unbounded)
          Begins a new transaction
 void commit()
          Commits the current transaction
 ITransaction current()
          Returns the current transaction associated with this thread.
 void removeTransactionListener(ITransactionListener listener)
          Removes a transaction listener
 void rollback()
          Rollback the current transaction
 

Method Detail

current

ITransaction current()
Returns the current transaction associated with this thread.

Returns:
current transaction

begin

ITransaction begin(boolean unbounded)
                   throws IllegalStateException
Begins a new transaction

Parameters:
unbounded - true if an unbounded transaction will be created
Returns:
new transaction
Throws:
IllegalStateException - thrown if there is an active transaction associated with this thread

commit

void commit()
            throws IllegalStateException
Commits the current transaction

Throws:
IllegalStateException - thrown if there is no active transaction or if there was a problem while commiting

rollback

void rollback()
              throws IllegalStateException
Rollback the current transaction

Throws:
IllegalStateException - thrown if there is no active transaction or if there was a problem while rolling back

addTransactionListener

void addTransactionListener(ITransactionListener listener)
Adds a transaction listener

Parameters:
listener -

removeTransactionListener

void removeTransactionListener(ITransactionListener listener)
Removes a transaction listener

Parameters:
listener -


Copyright © 2008. All Rights Reserved.