public abstract class BaseConnectionSource extends Object implements ConnectionSource
Constructor and Description |
---|
BaseConnectionSource() |
Modifier and Type | Method and Description |
---|---|
protected boolean |
clearSpecial(DatabaseConnection connection,
Logger logger)
Clear the connection that was previously saved.
|
protected DatabaseConnection |
getSavedConnection()
Returns the connection that has been saved or null if none.
|
DatabaseConnection |
getSpecialConnection(String tableName)
Return the currently saved connection or null if none.
|
protected boolean |
isSavedConnection(DatabaseConnection connection)
Return true if the connection being released is the one that has been saved.
|
protected boolean |
isSingleConnection(DatabaseConnection conn1,
DatabaseConnection conn2)
Return true if the two connections seem to one one connection under the covers.
|
protected boolean |
saveSpecial(DatabaseConnection connection)
Save this connection as our special connection to be returned by the
getSavedConnection() method. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
clearSpecialConnection, closeQuietly, getDatabaseType, getReadOnlyConnection, getReadWriteConnection, isOpen, isSingleConnection, releaseConnection, saveSpecialConnection
close
public DatabaseConnection getSpecialConnection(String tableName)
ConnectionSource
getSpecialConnection
in interface ConnectionSource
protected DatabaseConnection getSavedConnection()
protected boolean isSavedConnection(DatabaseConnection connection)
protected boolean saveSpecial(DatabaseConnection connection) throws SQLException
getSavedConnection()
method.SQLException
protected boolean clearSpecial(DatabaseConnection connection, Logger logger)
protected boolean isSingleConnection(DatabaseConnection conn1, DatabaseConnection conn2) throws SQLException
SQLException
This documentation is licensed by Gray Watson under the Creative Commons Attribution-Share Alike 3.0 License.