FileDocCategorySizeDatePackage
DummyTransactionManager.javaAPI DocHibernate 3.2.52190Fri Jun 03 11:10:00 BST 2005org.hibernate.test.tm

DummyTransactionManager

public class DummyTransactionManager extends Object implements TransactionManager
author
Gavin King

Fields Summary
public static DummyTransactionManager
INSTANCE
private DummyTransaction
current
org.hibernate.connection.ConnectionProvider
connections
Constructors Summary
public DummyTransactionManager(Properties props)

		connections = ConnectionProviderFactory.newConnectionProvider();
	
Methods Summary
public voidbegin()

		current = new DummyTransaction(this);
		current.begin();
	
public voidcommit()

		current.commit();
	
voidendCurrent(DummyTransaction tx)

		if (current==tx) current=null;
	
public DummyTransactiongetCurrent()

		return current;
	
public intgetStatus()

		return current.getStatus();
	
public javax.transaction.TransactiongetTransaction()

		return current;
	
public voidresume(javax.transaction.Transaction tx)

		current = (DummyTransaction) tx;
	
public voidrollback()

		current.rollback();

	
public voidsetRollbackOnly()

		current.setRollbackOnly();
	
public voidsetTransactionTimeout(int t)

	
public javax.transaction.Transactionsuspend()

		Transaction result = current;
		current = null;
		return result;