org.apache.commons.scaffold.sql
Class PoolmanAdaptor

java.lang.Object
  extended by org.apache.commons.scaffold.sql.ConnectionAdaptor
      extended by org.apache.commons.scaffold.sql.PoolmanAdaptor

public class PoolmanAdaptor
extends ConnectionAdaptor


Field Summary
 
Fields inherited from class org.apache.commons.scaffold.sql.ConnectionAdaptor
DATA_SOURCE_KEY, datasource, JNDI_CONTEXT_KEY, pool
 
Constructor Summary
PoolmanAdaptor()
           
 
Method Summary
protected  DataSource getDataSource(String key)
          Return datasource using JNDI lookup.
 
Methods inherited from class org.apache.commons.scaffold.sql.ConnectionAdaptor
getConnection, getConnection, getKey, getMessage, getPool, setKey, setMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PoolmanAdaptor

public PoolmanAdaptor()
Method Detail

getDataSource

protected DataSource getDataSource(String key)
                            throws SQLException
Description copied from class: ConnectionAdaptor
Return datasource using JNDI lookup. Subclasses may override this method to provide other means of obtaining a datasource reference.

Overrides:
getDataSource in class ConnectionAdaptor
Parameters:
key - The attribute name for the resource. If null is passed, null is returned.
Returns:
null or the datasource object related to "key" TODO: Add cache to store references to the datasources by key.
Throws:
SQLException


Copyright © 2001-2010 The Apache Software Foundation. All Rights Reserved.