com.scooterframework.orm.sqldataexpress.connection
Class JdbcConnectionContext

java.lang.Object
  extended by com.scooterframework.orm.sqldataexpress.connection.DatabaseConnectionContextImpl
      extended by com.scooterframework.orm.sqldataexpress.connection.JdbcConnectionContext
All Implemented Interfaces:
DatabaseConnectionContext, java.io.Serializable

public class JdbcConnectionContext
extends DatabaseConnectionContextImpl

JdbcConnectionContext class

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.scooterframework.orm.sqldataexpress.connection.DatabaseConnectionContextImpl
afterConnectionClassName, afterConnectionMethodName, autoCommit, beforeConnectionClassName, beforeConnectionMethodName, connectionName, loginTimeout, password, properties, readonly, roles, schema, transactionIsolationLevel, useLoginAsSchema, useLoginForConnection, username, vendor
 
Fields inherited from interface com.scooterframework.orm.sqldataexpress.connection.DatabaseConnectionContext
KEY_ACQUIRE_INCREMENT, KEY_AFTER_CONNECTION, KEY_AUTOCOMMIT, KEY_BEFORE_CONNECTION, KEY_CONNECTION_NAME, KEY_DATASOURCENAME, KEY_DRIVER, KEY_INITIAL_POOL_SIZE, KEY_LOGINTIMEOUT, KEY_MAX_IDLE_TIME, KEY_MAX_POOL_SIZE, KEY_MIN_POOL_SIZE, KEY_PASSWORD, KEY_READONLY, KEY_SCHEMA, KEY_TRANSACTION_ISOLATION_LEVEL, KEY_URL, KEY_USE_LOGIN_AS_SCHEMA, KEY_USE_LOGIN_FOR_CONNECTION, KEY_USERNAME, KEY_VENDOR
 
Constructor Summary
JdbcConnectionContext(java.util.Properties prop)
          Initializes database connection context
JdbcConnectionContext(java.lang.String connectionName, java.lang.String username, java.lang.String password)
          Initializes database connection context
JdbcConnectionContext(java.lang.String connectionName, java.lang.String driverClassName, java.lang.String url, java.lang.String username, java.lang.String password)
          Initializes database connection context
 
Method Summary
 int getAcquireIncrement()
          Returns number of connections at a time framework will try to acquire when the pool is exhausted
 java.lang.String getDriverClassName()
          Returns the driver class name of the database
 int getInitialPoolSize()
          Returns number of connections a pool will try to acquire upon startup
 int getMaxIdleTime()
          Returns seconds a connection can remain pooled but unused before being discarded
 int getMaxPoolSize()
          Returns maximum number of connections a pool will maintain at any given time
 int getMinPoolSize()
          Returns minimum number of connections a pool will maintain at any given time
 java.lang.String getUrl()
          Returns the url of the database
 java.lang.String getVendor()
          Returns the vendor name of the database
 boolean useConnectionPool()
          Checks to see if connection pool needs to be used.
 
Methods inherited from class com.scooterframework.orm.sqldataexpress.connection.DatabaseConnectionContextImpl
checkVendor, getAfterConnectionClassName, getAfterConnectionMethodName, getBeforeConnectionClassName, getBeforeConnectionMethodName, getConnectionName, getConnectionRoles, getLoginTimeout, getPassword, getProperties, getSchema, getTransactionIsolationLevel, getUsername, hasSpecifiedTransactionIsolationLevel, isAutoCommit, isReadonly, setAutoCommit, setConnectionRoles, setLoginTimeout, setProperties, setReadonly, useLoginAsSchema, useLoginForConnection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JdbcConnectionContext

public JdbcConnectionContext(java.util.Properties prop)
Initializes database connection context


JdbcConnectionContext

public JdbcConnectionContext(java.lang.String connectionName,
                             java.lang.String driverClassName,
                             java.lang.String url,
                             java.lang.String username,
                             java.lang.String password)
Initializes database connection context


JdbcConnectionContext

public JdbcConnectionContext(java.lang.String connectionName,
                             java.lang.String username,
                             java.lang.String password)
Initializes database connection context

Method Detail

getDriverClassName

public java.lang.String getDriverClassName()
Returns the driver class name of the database

Returns:
String

getUrl

public java.lang.String getUrl()
Returns the url of the database

Returns:
String

getVendor

public java.lang.String getVendor()
Returns the vendor name of the database

Specified by:
getVendor in interface DatabaseConnectionContext
Overrides:
getVendor in class DatabaseConnectionContextImpl
Returns:
String

getMaxPoolSize

public int getMaxPoolSize()
Returns maximum number of connections a pool will maintain at any given time

Returns:
int

getMinPoolSize

public int getMinPoolSize()
Returns minimum number of connections a pool will maintain at any given time

Returns:
int

getAcquireIncrement

public int getAcquireIncrement()
Returns number of connections at a time framework will try to acquire when the pool is exhausted

Returns:
int

getInitialPoolSize

public int getInitialPoolSize()
Returns number of connections a pool will try to acquire upon startup

Returns:
int

getMaxIdleTime

public int getMaxIdleTime()
Returns seconds a connection can remain pooled but unused before being discarded

Returns:
int

useConnectionPool

public boolean useConnectionPool()
Checks to see if connection pool needs to be used.

Returns:
true for using connection pool