DODS 7.1 API

com.lutris.appserver.server.sql.standard
Class StandardDBConnection

java.lang.Object
  extended by com.lutris.appserver.server.sql.ExtendedDBConnection
      extended by com.lutris.appserver.server.sql.standard.StandardDBConnection
All Implemented Interfaces:
com.lutris.appserver.server.sql.DBConnection
Direct Known Subclasses:
InformixDBConnection, OracleDBConnection

public class StandardDBConnection
extends ExtendedDBConnection

Standard implementation of the DBConnection object.

Since:
LBS1.7
Version:
$Revision: 1.5 $
Author:
Mark Diekhans, Kyle Clark
See Also:
DBConnection

Field Summary
 long curtime
           
 
Fields inherited from class com.lutris.appserver.server.sql.ExtendedDBConnection
allocated, closed, connection, connectionAllocator, connectionEnterPoolTime, connectionUsageCounter, currentStmt, dropConnection, dropped, generation, id, logging, maxPreparedStmts, nextId, password, preparedStmtCache, prepareStatementCache, psCacheLatency, reset, url, user
 
Constructor Summary
StandardDBConnection(com.lutris.appserver.server.sql.ConnectionAllocator connectionAllocatorObj, java.lang.String url, java.lang.String user, java.lang.String password, int maxPreparedStatements, boolean logging, int generation)
          Initialize the connection to a database.
 
Method Summary
 void release()
          Return this connection to its allocator.
 
Methods inherited from class com.lutris.appserver.server.sql.ExtendedDBConnection
allocate, allocatedCheck, allocateObjectId, close, closedCheck, commit, drop, execute, executeQuery, executeQuery, executeUpdate, executeUpdate, getConnection, getConnectionEnterPoolTime, getConnectionUsageCounter, getDatabaseName, getGeneration, getMaxPreparedStmts, getResultSetConcurrency, getResultSetType, getUrl, getUser, handleException, incrRequestCount, isClosed, isDroped, isMarkedForDrop, logDebug, logDebug, prepareCall, prepareStatement, prepareStatement, prepareStatement, reset, resetCheck, rollback, setAutoCommit, setConnectionEnterPoolTime, setConnectionUsageCounter, validate, warningCheck
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

curtime

public long curtime
Constructor Detail

StandardDBConnection

public StandardDBConnection(com.lutris.appserver.server.sql.ConnectionAllocator connectionAllocatorObj,
                            java.lang.String url,
                            java.lang.String user,
                            java.lang.String password,
                            int maxPreparedStatements,
                            boolean logging,
                            int generation)
                     throws java.sql.SQLException
Initialize the connection to a database.

Parameters:
url - JDBC URL of database.
user - SQL user name.
password - SQL password.
connectionAllocatorObj - The connection allocator that this connection belongs to.
maxPreparedStatements - Maximum number of preparse statements. a value of less than zero queries JDBC for the value.
logging - Specifying true enables SQL logging.
generation - A generation number used to drop old connection when they are released.
Throws:
java.sql.SQLException - If a connection can't be established.
Method Detail

release

public void release()
Return this connection to its allocator. This object should not be used after calling this function.

Specified by:
release in interface com.lutris.appserver.server.sql.DBConnection
Specified by:
release in class ExtendedDBConnection

DODS 7.1 API