Package com.swiftmq.amqp.v100.client
Class TransactionController
- java.lang.Object
-
- com.swiftmq.amqp.v100.client.TransactionController
-
public class TransactionController extends java.lang.Object
A transaction controller controls transactions of a session.
It communicates withe the transactional resources of the remote server.
- Author:
- IIT Software GmbH, Bremen/Germany, (c) 2011, All Rights Reserved
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
TransactionController(Session mySession)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
close()
void
commit(TxnIdIF txnId)
Commits a transaction.TxnIdIF
createTxnId()
Creates a new transaction id.boolean
isSupportDistributedTransactions()
Returns whether the attached server-side transactional resource supports distributed transactions.boolean
isSupportLocalTransactions()
Returns whether the attached server-side transactional resource supports local transactions.boolean
isSupportMultiSsnsPerTxn()
Returns whether the attached server-side transactional resource supports multiple sessions per transaction.boolean
isSupportMultiTxnsPerSsn()
Returns whether the attached server-side transactional resource supports multiple transactions per session.boolean
isSupportPromotableTransactions()
Returns whether the attached server-side transactional resource supports promotable transactions.void
rollback(TxnIdIF txnId)
Rolls back a transaction.java.lang.String
toString()
-
-
-
Constructor Detail
-
TransactionController
protected TransactionController(Session mySession)
-
-
Method Detail
-
createTxnId
public TxnIdIF createTxnId() throws AMQPException
Creates a new transaction id.- Returns:
- transaction id
- Throws:
AMQPException
- on error
-
commit
public void commit(TxnIdIF txnId) throws AMQPException
Commits a transaction.- Parameters:
txnId
- transaction id.- Throws:
AMQPException
- on error
-
rollback
public void rollback(TxnIdIF txnId) throws AMQPException
Rolls back a transaction.- Parameters:
txnId
- transaction id.- Throws:
AMQPException
- on error
-
isSupportLocalTransactions
public boolean isSupportLocalTransactions()
Returns whether the attached server-side transactional resource supports local transactions.- Returns:
- true/false
-
isSupportDistributedTransactions
public boolean isSupportDistributedTransactions()
Returns whether the attached server-side transactional resource supports distributed transactions.- Returns:
- true/false
-
isSupportPromotableTransactions
public boolean isSupportPromotableTransactions()
Returns whether the attached server-side transactional resource supports promotable transactions.- Returns:
- true/false
-
isSupportMultiTxnsPerSsn
public boolean isSupportMultiTxnsPerSsn()
Returns whether the attached server-side transactional resource supports multiple transactions per session.- Returns:
- true/false
-
isSupportMultiSsnsPerTxn
public boolean isSupportMultiSsnsPerTxn()
Returns whether the attached server-side transactional resource supports multiple sessions per transaction.- Returns:
- true/false
-
close
protected void close()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-