public class LdapConnectionProvider extends Object
This class is not thread safe.
Constructor and Description |
---|
LdapConnectionProvider()
Default constructor calls the init method which initializes the connection pools.
|
Modifier and Type | Method and Description |
---|---|
void |
closeAdminConnection(org.apache.directory.ldap.client.api.LdapConnection connection)
Calls the PoolMgr to close the Admin LDAP connection.
|
static void |
closeAllConnectionPools()
Closes all the ldap connection pools.
|
void |
closeLogConnection(org.apache.directory.ldap.client.api.LdapConnection connection)
Calls the PoolMgr to close the Log LDAP connection.
|
void |
closeUserConnection(org.apache.directory.ldap.client.api.LdapConnection connection)
Calls the PoolMgr to close the User LDAP connection.
|
org.apache.directory.ldap.client.api.LdapConnection |
getAdminConnection()
Calls the PoolMgr to get an Admin connection to the LDAP server.
|
static LdapConnectionProvider |
getInstance()
Synchronized getter guards access to reference to self which is a singleton and only be created the first time invoked.
|
org.apache.directory.ldap.client.api.LdapConnection |
getLogConnection()
Calls the PoolMgr to get an Log connection to the LDAP server.
|
org.apache.directory.ldap.client.api.LdapConnection |
getUserConnection()
Calls the PoolMgr to get an User connection to the LDAP server.
|
public LdapConnectionProvider()
public static LdapConnectionProvider getInstance()
public void closeAdminConnection(org.apache.directory.ldap.client.api.LdapConnection connection)
connection
- handle to ldap connection object.public void closeLogConnection(org.apache.directory.ldap.client.api.LdapConnection connection)
connection
- handle to ldap connection object.public void closeUserConnection(org.apache.directory.ldap.client.api.LdapConnection connection)
connection
- handle to ldap connection object.public org.apache.directory.ldap.client.api.LdapConnection getAdminConnection() throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
- If we had an issue getting an LDAP connectionpublic org.apache.directory.ldap.client.api.LdapConnection getLogConnection() throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
- If we had an issue getting an LDAP connectionpublic org.apache.directory.ldap.client.api.LdapConnection getUserConnection() throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
- If we had an issue getting an LDAP connectionpublic static void closeAllConnectionPools()
Copyright © 2003-2016, The Apache Software Foundation. All Rights Reserved. Generated 20160718-1621