org.apache.cayenne.conn
Class PoolDataSource
java.lang.Object
org.apache.cayenne.conn.PoolDataSource
- All Implemented Interfaces:
- ConnectionPoolDataSource
public class PoolDataSource
- extends Object
- implements ConnectionPoolDataSource
PoolDataSource allows to generate pooled connections.
It is implemented as a wrapper around a non-pooled data source object.
Delegates all method calls except for "getPooledConnection" to the underlying
datasource.
- Author:
- Andrus Adamchik
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PoolDataSource
public PoolDataSource(DataSource nonPooledDatasource)
- Creates new PoolDataSource
PoolDataSource
public PoolDataSource(String jdbcDriver,
String connectionUrl)
throws SQLException
- Throws:
SQLException
getLoginTimeout
public int getLoginTimeout()
throws SQLException
- Specified by:
getLoginTimeout
in interface ConnectionPoolDataSource
- Throws:
SQLException
setLoginTimeout
public void setLoginTimeout(int seconds)
throws SQLException
- Specified by:
setLoginTimeout
in interface ConnectionPoolDataSource
- Throws:
SQLException
getLogWriter
public PrintWriter getLogWriter()
throws SQLException
- Specified by:
getLogWriter
in interface ConnectionPoolDataSource
- Throws:
SQLException
setLogWriter
public void setLogWriter(PrintWriter out)
throws SQLException
- Specified by:
setLogWriter
in interface ConnectionPoolDataSource
- Throws:
SQLException
getPooledConnection
public PooledConnection getPooledConnection()
throws SQLException
- Specified by:
getPooledConnection
in interface ConnectionPoolDataSource
- Throws:
SQLException
getPooledConnection
public PooledConnection getPooledConnection(String user,
String password)
throws SQLException
- Specified by:
getPooledConnection
in interface ConnectionPoolDataSource
- Throws:
SQLException
Copyright © 2001-2007 Apache Cayenne. All Rights Reserved.