|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javatools.db.DbConnection
A Database connection.
Constructor Summary | |
DbConnection(DbDatabase database,
java.sql.Connection con)
Creates a new DbConnection. |
Method Summary | |
void |
close()
Closes the connection. |
void |
commit()
Commits all operations. |
void |
commitClose()
Commits all the operations and closes the connection. |
protected void |
finalize()
Destroys this object. |
java.sql.Connection |
getSqlConnection()
Returns the real JDBC connection. |
boolean |
isClosed()
Checks if this connection is closed. |
void |
rollback()
Rollbacks operations. |
void |
rollbackClose()
Rollbacks operations and closes the connection. |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DbConnection(DbDatabase database, java.sql.Connection con)
database
- The database to connect to.con
- The real JDBC connection.Method Detail |
public java.sql.Connection getSqlConnection()
public boolean isClosed() throws DbException
true
: if this connection is closed;
false
: if it is open.
DbException
- If something goes wrong.public void commitClose() throws DbException
DbException
- If something goes wrong.public void rollbackClose() throws DbException
DbException
- If something goes wrong.public void commit() throws DbException
DbException
- If something goes wrong.public void rollback() throws DbException
DbException
- If something goes wrong.public void close() throws DbException
DbException
- If something goes wrong.protected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
- If something goes wrong.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |