net.esper.eql.db
Class DatabaseDSConnFactory

java.lang.Object
  extended by net.esper.eql.db.DatabaseDSConnFactory
All Implemented Interfaces:
DatabaseConnectionFactory

public class DatabaseDSConnFactory
extends Object
implements DatabaseConnectionFactory

Database connection factory using InitialContext and DataSource to obtain connections.


Constructor Summary
DatabaseDSConnFactory(ConfigurationDBRef.DataSourceConnection dsConfig, ConfigurationDBRef.ConnectionSettings connectionSettings)
          Ctor.
 
Method Summary
 Connection getConnection()
          Creates a new database connection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DatabaseDSConnFactory

public DatabaseDSConnFactory(ConfigurationDBRef.DataSourceConnection dsConfig,
                             ConfigurationDBRef.ConnectionSettings connectionSettings)
Ctor.

Parameters:
dsConfig - is the datasource object name and initial context properties.
connectionSettings - are the connection-level settings
Method Detail

getConnection

public Connection getConnection()
                         throws DatabaseConfigException
Description copied from interface: DatabaseConnectionFactory
Creates a new database connection.

Specified by:
getConnection in interface DatabaseConnectionFactory
Returns:
new connection
Throws:
DatabaseConfigException - throws to indicate a problem getting a new connection

© 2007 EsperTech Inc.
All rights reserved.
Visit us at espertech.com