All LDAP Classes
Internal LDAP Classes

org.ietf.ldap
Class LDAPConstraints.BindHandlerImpl

java.lang.Object
  extended by org.ietf.ldap.LDAPConstraints.BindHandlerImpl
All Implemented Interfaces:
LDAPBindHandler, LDAPReferralHandler
Enclosing class:
LDAPConstraints

private class LDAPConstraints.BindHandlerImpl
extends java.lang.Object
implements LDAPBindHandler

Wrapper object for LDAPBindHandler LDAPReferralHandler


Field Summary
(package private)  LDAPBindHandler ref
           
 
Constructor Summary
private LDAPConstraints.BindHandlerImpl(LDAPBindHandler ref)
           
 
Method Summary
 LDAPConnection bind(java.lang.String[] ldapurl, LDAPConnection conn)
          Called by LDAPConnection when a referral is received.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ref

LDAPBindHandler ref
Constructor Detail

LDAPConstraints.BindHandlerImpl

private LDAPConstraints.BindHandlerImpl(LDAPBindHandler ref)
Method Detail

bind

public LDAPConnection bind(java.lang.String[] ldapurl,
                           LDAPConnection conn)
                    throws LDAPReferralException
Description copied from interface: LDAPBindHandler
Called by LDAPConnection when a referral is received.

This method has the responsibility to bind to one of the hosts in the list specified by the ldaprul parameter which corresponds exactly to the list of hosts returned in a single referral response. An implementation may access the host, port, credentials, and other information in the original LDAPConnection object to decide on an appropriate authentication mechanism, and/or interact with a user or external module. The object implementing LDAPBind creates a new LDAPConnection object to perform its connect and bind calls. It returns the new connection when both the connect and bind operations succeed on one host from the list. The LDAPConnection object referral following code uses the new LDAPConnection object when it resends the search request, updated with the new search base and possible search filter. An LDAPException is thrown on failure, as in the LDAPConnection.bind method.

Specified by:
bind in interface LDAPBindHandler
Parameters:
ldapurl - The list of servers contained in a referral response.
conn - An established connection to an LDAP server.
Returns:
An established connection to one of the ldap servers in the referral list.
Throws:
LDAPReferralException - An LDAPreferralException is thrown with appropriate fields set to give the reason for the failure.

All LDAP Classes
Internal LDAP Classes

Copyright ? 2002 Novell, Inc. All Rights Reserved.
Novell, Inc.
1800 South Novell Place
Provo, Ut 84606
Phone: (801) 861-5000