Sun Adapter for LDAP API

com.stc.connector.ldapadapter.appconn
Class LDAPClientApplicationImpl

java.lang.Object
  extended by com.stc.connector.appconn.ldap.ConnectionConstants
      extended by com.stc.connector.ldapadapter.appconn.LDAPClientApplicationImpl
All Implemented Interfaces:
LDAPClientApplication
Direct Known Subclasses:
NonManagedLDAPClientApplicationImpl

public class LDAPClientApplicationImpl
extends ConnectionConstants
implements LDAPClientApplication

This class is the LDAP client through which the application interacts with the LDAP Server. It creates objects for various directory operations that can be executed on the server. This class is the entry point for all operations on the LDAP Server.

Version:
Author:

Field Summary
protected  AddEntryImpl addEntry
           
protected  LDAPApplicationConnection appConn
           
protected  CompareEntryImpl compareEntry
           
protected  LDAPConnector ldapConnector
           
protected  ModifyEntryImpl modifyEntry
           
protected  PersistentSearch persistentSearch
           
protected  RemoveEntryImpl removeEntry
           
protected  RenameEntryImpl renameEntry
           
protected  SearchImpl search
           
protected  TimestampSearch timestampSearch
           
protected  StartTLSExtension tlsExtension
           
 
Fields inherited from class com.stc.connector.appconn.ldap.ConnectionConstants
anonymousLoginMandatoryProperties, CONN_AUTHENTICATION, CONN_CREDENTIALS, CONN_INITIALCONTEXT_FACTORY, CONN_PRINCIPAL, CONN_PROVIDER_URL, connectionDefaultValuesMap, LDAP_ATTRIBUTES, LOCAL_HOST_PROVIDER_URL, NO_AUTHENTICATION, REFERRAL_CREDENTIALS_FILE, REFERRAL_FOLLOW, SECURITY_CONNECTION_TYPE, SECURITY_KEYSTORE, SECURITY_KEYSTORE_PASSWORD, SECURITY_KEYSTORE_TYPE, SECURITY_KEYSTORE_USER_NAME, SECURITY_PROTOCOL, SECURITY_PROVIDER, SECURITY_TRUSTSTORE, SECURITY_TRUSTSTORE_PASSWORD, SECURITY_TRUSTSTORE_TYPE, SECURITY_VERIFY_HOSTNAME, SECURITY_X509_ALGORITHM, SIMPLE_AUTHENTICATION, simpleLoginMandatoryProperties
 
Constructor Summary
protected LDAPClientApplicationImpl()
           
  LDAPClientApplicationImpl(LDAPApplicationConnection appConn)
          Creates a new instance of LDAPClientApplicationImpl
 
Method Summary
 void checkIfClosed()
          Checks whether the application connection was closed.
 AddEntry getAddEntry()
          Gets the instance of the class that is used to perform Add operation
protected  com.stc.connector.appconn.common.ApplicationConnection getApplicationConnection()
          Gets the LDAP application connection which created this instance of LDAPClientApplication.
 CompareEntry getCompareEntry()
          Gets the instance of the class that is used to perform Compare operation
protected  LDAPConnector getLDAPConnection()
           
 ModifyEntry getModifyEntry()
          Gets the instance of the class that is used to perform Modify operation
 PersistentSearch getPersistentSearch()
          Gets the instance of the class that is used to perform Persistent Search.
 RemoveEntry getRemoveEntry()
          Gets the instance of the class that is used to perform Remove operation
 RenameEntry getRenameEntry()
          Gets the instance of the class that is used to perform Rename operation
 Search getSearch()
          Gets the instance of the class that is used to perform Search operation
 TimestampSearch getTimestampSearch()
          Gets the instance of the class that is used to track updates on the LDAP server.
 StartTLSExtension getTlsExtension()
          Gets the instance of the class that is used to enable TLS on demand.
protected  void initialize(java.lang.Class aClass)
           
 void reset()
          Method to reset the values
 
Methods inherited from class com.stc.connector.appconn.ldap.ConnectionConstants
contains, getDefaultBooleanValue, getDefaultStringValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

appConn

protected LDAPApplicationConnection appConn

ldapConnector

protected LDAPConnector ldapConnector

addEntry

protected AddEntryImpl addEntry

renameEntry

protected RenameEntryImpl renameEntry

removeEntry

protected RemoveEntryImpl removeEntry

modifyEntry

protected ModifyEntryImpl modifyEntry

compareEntry

protected CompareEntryImpl compareEntry

search

protected SearchImpl search

persistentSearch

protected PersistentSearch persistentSearch

timestampSearch

protected TimestampSearch timestampSearch

tlsExtension

protected StartTLSExtension tlsExtension
Constructor Detail

LDAPClientApplicationImpl

protected LDAPClientApplicationImpl()

LDAPClientApplicationImpl

public LDAPClientApplicationImpl(LDAPApplicationConnection appConn)
                          throws LDAPApplicationException
Creates a new instance of LDAPClientApplicationImpl

Parameters:
appConn - The application connection which created this instance of application.
Throws:
LDAPApplicationException - if the connection to the LDAP server is not available
Method Detail

initialize

protected void initialize(java.lang.Class aClass)
                   throws LDAPApplicationException
Throws:
LDAPApplicationException

getLDAPConnection

protected LDAPConnector getLDAPConnection()

getApplicationConnection

protected com.stc.connector.appconn.common.ApplicationConnection getApplicationConnection()
Gets the LDAP application connection which created this instance of LDAPClientApplication.

Returns:
LDAPApplicationConnection instance.

checkIfClosed

public void checkIfClosed()
                   throws LDAPApplicationException
Checks whether the application connection was closed. If closed then an LDAPApplicationException is thrown.

Throws:
LDAPApplicationException - if the Application Connection associated with this application was already closed.

getAddEntry

public AddEntry getAddEntry()
                     throws LDAPApplicationException
Gets the instance of the class that is used to perform Add operation

Specified by:
getAddEntry in interface LDAPClientApplication
Returns:
the instance of AddEntry class associated with this client application
Throws:
LDAPApplicationException

getRenameEntry

public RenameEntry getRenameEntry()
                           throws LDAPApplicationException
Gets the instance of the class that is used to perform Rename operation

Specified by:
getRenameEntry in interface LDAPClientApplication
Returns:
the instance of RenameEntry class associated with this client application
Throws:
LDAPApplicationException

getRemoveEntry

public RemoveEntry getRemoveEntry()
                           throws LDAPApplicationException
Gets the instance of the class that is used to perform Remove operation

Specified by:
getRemoveEntry in interface LDAPClientApplication
Returns:
the instance of RemoveEntry class associated with this client application
Throws:
LDAPApplicationException

getModifyEntry

public ModifyEntry getModifyEntry()
                           throws LDAPApplicationException
Gets the instance of the class that is used to perform Modify operation

Specified by:
getModifyEntry in interface LDAPClientApplication
Returns:
the instance of ModifyEntry class associated with this client application
Throws:
LDAPApplicationException

getCompareEntry

public CompareEntry getCompareEntry()
                             throws LDAPApplicationException
Gets the instance of the class that is used to perform Compare operation

Specified by:
getCompareEntry in interface LDAPClientApplication
Returns:
the instance of CompareEntry class associated with this client application
Throws:
LDAPApplicationException

getSearch

public Search getSearch()
                 throws LDAPApplicationException
Gets the instance of the class that is used to perform Search operation

Specified by:
getSearch in interface LDAPClientApplication
Returns:
the instance of Search class associated with this client application
Throws:
LDAPApplicationException

getTlsExtension

public StartTLSExtension getTlsExtension()
                                  throws LDAPApplicationException
Gets the instance of the class that is used to enable TLS on demand. The instance so returned has methods for starting & stopping the TLS operation.

Specified by:
getTlsExtension in interface LDAPClientApplication
Returns:
the instance of StartTLSExtension class associated with this client application
Throws:
LDAPApplicationException

getPersistentSearch

public PersistentSearch getPersistentSearch()
                                     throws LDAPApplicationException
Gets the instance of the class that is used to perform Persistent Search. Persistent Search is a control supported by LDAP v3 that is used to track updates on the LDAP server.

Specified by:
getPersistentSearch in interface LDAPClientApplication
Returns:
the instance of PersistentSearch class associated with this client application
Throws:
LDAPApplicationException

getTimestampSearch

public TimestampSearch getTimestampSearch()
                                   throws LDAPApplicationException
Gets the instance of the class that is used to track updates on the LDAP server. where Persistent Search control is not supported. This class depends on the timestamp of the entries to track the updates.

Specified by:
getTimestampSearch in interface LDAPClientApplication
Returns:
the instance of TimestampSearch class associated with this client application
Throws:
LDAPApplicationException

reset

public void reset()
Method to reset the values

Specified by:
reset in interface LDAPClientApplication

Sun Adapter for LDAP API