org.apache.torque.dsfactory
Class PerUserPoolDataSourceFactory
java.lang.Object
org.apache.torque.dsfactory.AbstractDataSourceFactory
org.apache.torque.dsfactory.PerUserPoolDataSourceFactory
- All Implemented Interfaces:
- DataSourceFactory
public class PerUserPoolDataSourceFactory
- extends AbstractDataSourceFactory
A factory that looks up the DataSource using the JDBC2 pool methods.
- Version:
- $Id: PerUserPoolDataSourceFactory.java 1336091 2012-05-09 11:09:40Z tfischer $
- Author:
- John McNally, Henning P. Schmiedehausen
Method Summary |
void |
close()
Closes the pool associated with this factory and releases it. |
DataSource |
getDataSource()
|
void |
initialize(org.apache.commons.configuration.Configuration configuration)
Initialize the factory. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PerUserPoolDataSourceFactory
public PerUserPoolDataSourceFactory()
getDataSource
public DataSource getDataSource()
- Specified by:
getDataSource
in interface DataSourceFactory
- Specified by:
getDataSource
in class AbstractDataSourceFactory
- Returns:
- the
DataSource
configured by the factory. - See Also:
DataSourceFactory.getDataSource()
initialize
public void initialize(org.apache.commons.configuration.Configuration configuration)
throws TorqueException
- Description copied from class:
AbstractDataSourceFactory
- Initialize the factory.
- Specified by:
initialize
in interface DataSourceFactory
- Specified by:
initialize
in class AbstractDataSourceFactory
- Parameters:
configuration
- where to load the factory settings from
- Throws:
TorqueException
- Any exceptions caught during processing will be
rethrown wrapped into a TorqueException.- See Also:
DataSourceFactory.initialize(org.apache.commons.configuration.Configuration)
close
public void close()
throws TorqueException
- Closes the pool associated with this factory and releases it.
- Throws:
TorqueException
- if the pool cannot be closed properly
Copyright © 2000-2012 The Apache Software Foundation. All Rights Reserved.