Package lumis.portal.transaction
Interface ITransaction
-
- All Superinterfaces:
java.lang.AutoCloseable
,java.io.Closeable
,ITransaction
- All Known Subinterfaces:
ITransactionHibernate
,ITransactionJdbc
,ITransactionSPI
- All Known Implementing Classes:
TransactionHibernate
@StableMinor(version="15.0", sinceVersion="4.2") public interface ITransaction extends ITransaction
Represents a transaction that offers persistence access. An instance of transaction is not thread-safe.It is important to always call
ITransaction.close()
for a transaction after it is used. To guarantee this, it should be called inside afinally
block. (See code example inlumis.portal.transaction
).- Since:
- 4.2.0
- Version:
- $Revision: 25303 $ $Date: 2022-10-22 22:48:02 -0300 (Sat, 22 Oct 2022) $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ITransaction
getByConnectionId(java.lang.String id)
Returns anITransaction
that represents the same transaction but that returns the connection with the given id as default.-
Methods inherited from interface lumis.util.ITransaction
addObserver, begin, close, commit, dispose, getAttribute, isActive, removeAttribute, removeObserver, rollback, setAttribute
-
-
-
-
Method Detail
-
getByConnectionId
ITransaction getByConnectionId(java.lang.String id) throws DaoException
Description copied from interface:ITransaction
Returns anITransaction
that represents the same transaction but that returns the connection with the given id as default. How the id represents the connection is defined by the concrete class that implements this interface.- Specified by:
getByConnectionId
in interfaceITransaction
- Parameters:
id
- the connection id.- Returns:
- the ITransaction object.
- Throws:
DaoException
-
-