Sun Adapter for LDAP API

com.stc.connector.ldapadapter.appconn.nonmanaged
Class NonManagedLDAPApplicationConnection

java.lang.Object
  extended by com.stc.connector.appconn.ldap.ConnectionConstants
      extended by com.stc.connector.ldapadapter.appconn.nonmanaged.NonManagedLDAPApplicationConnection
All Implemented Interfaces:
com.stc.connector.appconn.common.ApplicationConnection

public class NonManagedLDAPApplicationConnection
extends ConnectionConstants
implements com.stc.connector.appconn.common.ApplicationConnection

This class represents an EIS connection(Physical Connection) handle for the Application Connection. Here the physical LDAP connections are created basded on the client input configuration and there is NO ManagedConnectionfactory creating and matching connections or connection pooling is done. The connection is created adhoc with the clients Input.

Version:
5.1.0
Author:
See Also:
ApplicationConnection, ConnectionConstants

Field Summary
 
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
NonManagedLDAPApplicationConnection(java.util.Properties properties)
          This creates physical LDAP connection to the LDAP Server using the given LDAP information .
NonManagedLDAPApplicationConnection(java.lang.String configuration)
          This creates physical LDAP connection to the LDAP Server using the given LDAP information .
 
Method Summary
protected  boolean checkIfClosed()
          Check whether the Connection instance was already closed (if close was previously called).
 void close()
          Closes the context to the LDAP external system and releases resources..
 java.lang.Object createApplication(java.lang.String appName)
          Creates an Application from the Application Connection.
 com.stc.connector.appconn.common.OutputHandler createOutputHandler()
          Creates an OutputHandler for "sending" data to the EIS.
protected  LDAPConnector getEISConnection()
          Returns the LDAPConnector
protected  javax.naming.Context getLDAPContext()
          Returns the real LDAP Context associated with this NM deployments
 
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
 

Constructor Detail

NonManagedLDAPApplicationConnection

public NonManagedLDAPApplicationConnection(java.util.Properties properties)
                                    throws LDAPApplicationConnectionException
This creates physical LDAP connection to the LDAP Server using the given LDAP information .

Parameters:
properties - - This properties represents the LDAP connection information
Throws:
LDAPApplicationConnectionException

NonManagedLDAPApplicationConnection

public NonManagedLDAPApplicationConnection(java.lang.String configuration)
                                    throws LDAPApplicationConnectionException
This creates physical LDAP connection to the LDAP Server using the given LDAP information .

Parameters:
properties - - This properties represents the LDAP connection information
Throws:
LDAPApplicationConnectionException
Method Detail

close

public void close()
           throws LDAPApplicationConnectionException
Closes the context to the LDAP external system and releases resources.. Once the close method is called, using the application created from the application connection must be forbidden and must result in an ApplicationConnectionException. The association between an application connection and the application is implementation specific.

Specified by:
close in interface com.stc.connector.appconn.common.ApplicationConnection
Throws:
com.stc.connector.appconn.common.ApplicationConnectionException - upon error.
LDAPApplicationConnectionException

createApplication

public java.lang.Object createApplication(java.lang.String appName)
                                   throws com.stc.connector.appconn.common.ApplicationException
Creates an Application from the Application Connection. The application is an API which can be used to interact with the underlying EIS. The application API must be invalidated once the close method is called on the Application Connection. If null is passed for the application name, then the default application will be created. Otherwise, the application name will be used to create the appropriate connection.

Specified by:
createApplication in interface com.stc.connector.appconn.common.ApplicationConnection
Parameters:
appName - The name of the application to create.
Returns:
A java.lang.Object representing the EIS specific application component to interact with the EIS.
Throws:
com.stc.connector.appconn.common.ApplicationException - upon error.

checkIfClosed

protected boolean checkIfClosed()
Check whether the Connection instance was already closed (if close was previously called).

Returns:
true if already closed, false otherwise.

createOutputHandler

public com.stc.connector.appconn.common.OutputHandler createOutputHandler()
                                                                   throws com.stc.connector.appconn.common.ApplicationException
Creates an OutputHandler for "sending" data to the EIS. If the eWay does not support an OutputHandler, then it should return null for its implementation of this method.

Specified by:
createOutputHandler in interface com.stc.connector.appconn.common.ApplicationConnection
Returns:
The eWay specific OutputHandler for handling "sending" data to the external system or null if the eWay does not have an OutputHandler.
Throws:
com.stc.connector.appconn.common.ApplicationException - upon error.

getEISConnection

protected LDAPConnector getEISConnection()
Returns the LDAPConnector

Returns:
ldapConnector

getLDAPContext

protected javax.naming.Context getLDAPContext()
Returns the real LDAP Context associated with this NM deployments

Returns:
Context - LDAP Context
Throws:
LDAPApplicationException
See Also:
NonManagedLDAPClientApplication.getLDAPContext()

Sun Adapter for LDAP API