public class DbContextTransactional extends DbContext
ERROR_CLOSED_CONNECTION
Constructor and Description |
---|
DbContextTransactional() |
Modifier and Type | Method and Description |
---|---|
void |
closeQuietly()
Close without causing exceptions.
|
void |
commit()
Commit changes.
|
void |
rollback()
Rollback changes.
|
protected void |
setConnection(JDBCConnectionCredentials connectionCredentials)
Set connections to database.
|
close, execute, execute, executeNullsAlllowed, getConnection, select, select
protected void setConnection(JDBCConnectionCredentials connectionCredentials) throws ConnectionException
DbContext
setConnection
in class DbContext
connectionCredentials
- credentials for connections to databaseConnectionException
public void closeQuietly()
closeQuietly
in class DbContext
public void commit() throws ConnectionException, DbTransactionException
ConnectionException
DbTransactionException
- - Exception for transactions abortpublic void rollback() throws ConnectionException, SQLException
ConnectionException
SQLException
Copyright © 2013. All Rights Reserved.