public class PooledConnectionFactory extends java.lang.Object implements ConnectionFactory
| Modifier and Type | Field and Description |
|---|---|
private ConnectionPool |
pool
Connection pool.
|
| Constructor and Description |
|---|
PooledConnectionFactory()
Default constructor.
|
PooledConnectionFactory(ConnectionPool cp)
Creates a new pooled connection factory.
|
| Modifier and Type | Method and Description |
|---|---|
Connection |
getConnection()
Returns a connection from the pool.
|
ConnectionPool |
getConnectionPool()
Returns the connection pool.
|
void |
setConnectionPool(ConnectionPool cp)
Sets the connection pool.
|
java.lang.String |
toString() |
private ConnectionPool pool
public PooledConnectionFactory()
public PooledConnectionFactory(ConnectionPool cp)
cp - connection poolpublic ConnectionPool getConnectionPool()
public void setConnectionPool(ConnectionPool cp)
cp - connection poolpublic Connection getConnection() throws LdapException
getConnection in interface ConnectionFactoryLdapException - if a connection cannot be retrieved from the poolpublic java.lang.String toString()
toString in class java.lang.Object