public class PoolableLdapConnectionFactory extends Object implements org.apache.commons.pool.PoolableObjectFactory<LdapConnection>
Constructor and Description |
---|
PoolableLdapConnectionFactory(LdapConnectionConfig config)
Creates a new instance of PoolableLdapConnectionFactory.
|
PoolableLdapConnectionFactory(LdapConnectionFactory connectionFactory)
Creates a new instance of PoolableLdapConnectionFactory.
|
Modifier and Type | Method and Description |
---|---|
void |
activateObject(LdapConnection connection) |
void |
destroyObject(LdapConnection connection) |
LdapApiService |
getLdapApiService()
Returns the LdapApiService instance used by this factory.
|
LdapConnection |
makeObject() |
void |
passivateObject(LdapConnection connection) |
boolean |
validateObject(LdapConnection connection) |
public PoolableLdapConnectionFactory(LdapConnectionConfig config)
config
- the configuration for creating LdapConnectionspublic PoolableLdapConnectionFactory(LdapConnectionFactory connectionFactory)
connectionFactory
- the connection factory for creating LdapConnectionspublic void activateObject(LdapConnection connection)
activateObject
in interface org.apache.commons.pool.PoolableObjectFactory<LdapConnection>
public void destroyObject(LdapConnection connection)
destroyObject
in interface org.apache.commons.pool.PoolableObjectFactory<LdapConnection>
public LdapApiService getLdapApiService()
public LdapConnection makeObject() throws LdapException
makeObject
in interface org.apache.commons.pool.PoolableObjectFactory<LdapConnection>
LdapException
- If unable to connect.public void passivateObject(LdapConnection connection) throws LdapException
passivateObject
in interface org.apache.commons.pool.PoolableObjectFactory<LdapConnection>
LdapException
- If unable to reconfigure and rebind.public boolean validateObject(LdapConnection connection)
validateObject
in interface org.apache.commons.pool.PoolableObjectFactory<LdapConnection>
Copyright © 2003–2014 The Apache Software Foundation. All rights reserved.