org.apache.commons.dbcp

Class PoolingDriver

public class PoolingDriver extends Object implements Driver

A Driver implementation that obtains Connections from a registered ObjectPool.

Version: $Revision: 1.12 $ $Date: 2004/05/17 18:39:44 $

Author: Rodney Waldhoff Dirk Verbeeck

Constructor Summary
PoolingDriver()
Method Summary
booleanacceptsURL(String url)
voidclosePool(String name)
Connectionconnect(String url, Properties info)
ObjectPoolgetConnectionPool(String name)
intgetMajorVersion()
intgetMinorVersion()
ObjectPoolgetPool(String name)
WARNING: This method throws DbcpExceptions (RuntimeExceptions) and will be replaced by the protected getConnectionPool method.
String[]getPoolNames()
DriverPropertyInfo[]getPropertyInfo(String url, Properties info)
static booleanisAccessToUnderlyingConnectionAllowed()
Returns the value of the accessToUnderlyingConnectionAllowed property.
booleanjdbcCompliant()
voidregisterPool(String name, ObjectPool pool)
static voidsetAccessToUnderlyingConnectionAllowed(boolean allow)
Sets the value of the accessToUnderlyingConnectionAllowed property.

Constructor Detail

PoolingDriver

public PoolingDriver()

Method Detail

acceptsURL

public boolean acceptsURL(String url)

closePool

public void closePool(String name)

connect

public Connection connect(String url, Properties info)

getConnectionPool

public ObjectPool getConnectionPool(String name)

getMajorVersion

public int getMajorVersion()

getMinorVersion

public int getMinorVersion()

getPool

public ObjectPool getPool(String name)

Deprecated: This will be removed in a future version of DBCP.

WARNING: This method throws DbcpExceptions (RuntimeExceptions) and will be replaced by the protected getConnectionPool method.

getPoolNames

public String[] getPoolNames()

getPropertyInfo

public DriverPropertyInfo[] getPropertyInfo(String url, Properties info)

isAccessToUnderlyingConnectionAllowed

public static boolean isAccessToUnderlyingConnectionAllowed()
Returns the value of the accessToUnderlyingConnectionAllowed property.

Returns: true if access to the underlying is allowed, false otherwise.

jdbcCompliant

public boolean jdbcCompliant()

registerPool

public void registerPool(String name, ObjectPool pool)

setAccessToUnderlyingConnectionAllowed

public static void setAccessToUnderlyingConnectionAllowed(boolean allow)
Sets the value of the accessToUnderlyingConnectionAllowed property. It controls if the PoolGuard allows access to the underlying connection. (Default: false)

Parameters: allow Access to the underlying connection is granted when true.

Copyright © 2001-2003 Apache Software Foundation. Documenation generated February 19 2008.