public class ManagedTransactionFactory extends Object implements TransactionFactory
Constructor and Description |
---|
ManagedTransactionFactory() |
Modifier and Type | Method and Description |
---|---|
Transaction |
newTransaction(Connection conn)
Creates a
Transaction out of an existing connection. |
Transaction |
newTransaction(DataSource ds,
TransactionIsolationLevel level,
boolean autoCommit)
Creates a
Transaction out of a datasource. |
void |
setProperties(Properties props)
Sets transaction factory custom properties.
|
public void setProperties(Properties props)
TransactionFactory
setProperties
in interface TransactionFactory
public Transaction newTransaction(Connection conn)
TransactionFactory
Transaction
out of an existing connection.newTransaction
in interface TransactionFactory
conn
- Existing database connectionpublic Transaction newTransaction(DataSource ds, TransactionIsolationLevel level, boolean autoCommit)
TransactionFactory
Transaction
out of a datasource.newTransaction
in interface TransactionFactory
ds
- DataSource to take the connection fromlevel
- Desired isolation levelautoCommit
- Desired autocommitCopyright © 2010–2015 MyBatis.org. All rights reserved.