Class LDAPReferralException
java.lang.Object
java.lang.Throwable
java.lang.Exception
netscape.ldap.LDAPException
netscape.ldap.LDAPReferralException
- All Implemented Interfaces:
Serializable
Represents the situation in which the LDAP server refers the client to
another LDAP server. This exception constructs a list of referral URLs from
the LDAP error message returned by the server. You can get this list by
using the
getURLs method.- Version:
- 1.0
- See Also:
-
Field Summary
Fields inherited from class LDAPException
ADMIN_LIMIT_EXCEEDED, AFFECTS_MULTIPLE_DSAS, ALIAS_DEREFERENCING_PROBLEM, ALIAS_PROBLEM, ATTRIBUTE_OR_VALUE_EXISTS, AUTH_METHOD_NOT_SUPPORTED, BUSY, CLIENT_LOOP, COMPARE_FALSE, COMPARE_TRUE, CONFIDENTIALITY_REQUIRED, CONNECT_ERROR, CONSTRAINT_VIOLATION, CONTROL_NOT_FOUND, ENTRY_ALREADY_EXISTS, INAPPROPRIATE_AUTHENTICATION, INAPPROPRIATE_MATCHING, INDEX_RANGE_ERROR, INSUFFICIENT_ACCESS_RIGHTS, INVALID_ATTRIBUTE_SYNTAX, INVALID_CREDENTIALS, INVALID_DN_SYNTAX, IS_LEAF, LDAP_NOT_SUPPORTED, LDAP_PARTIAL_RESULTS, LDAP_TIMEOUT, LOOP_DETECT, MORE_RESULTS_TO_RETURN, NAMING_VIOLATION, NO_RESULTS_RETURNED, NO_SUCH_ATTRIBUTE, NO_SUCH_OBJECT, NOT_ALLOWED_ON_NONLEAF, NOT_ALLOWED_ON_RDN, OBJECT_CLASS_MODS_PROHIBITED, OBJECT_CLASS_VIOLATION, OPERATION_ERROR, OTHER, PARAM_ERROR, PROTOCOL_ERROR, REFERRAL, REFERRAL_LIMIT_EXCEEDED, SASL_BIND_IN_PROGRESS, SERVER_DOWN, SIZE_LIMIT_EXCEEDED, SORT_CONTROL_MISSING, STRONG_AUTH_REQUIRED, SUCCESS, TIME_LIMIT_EXCEEDED, TLS_NOT_SUPPORTED, UNAVAILABLE, UNAVAILABLE_CRITICAL_EXTENSION, UNDEFINED_ATTRIBUTE_TYPE, UNWILLING_TO_PERFORMModifier and TypeFieldDescriptionstatic final int(11) [LDAP v3] The adminstrative limit on the maximum number of entries to return was exceeded.static final int(71) [LDAP v3] The client attempted to move an entry from one LDAP server to another by requesting a "modify DN" operation.static final int(36) An error occurred when dereferencing an alias.static final int(33) An problem occurred with an alias.static final int(20) The value that you are adding to an attribute already exists in the attribute.static final int(7) The specified authentication method is not supported by the LDAP server that you are connecting to.static final int(51) The LDAP server is busy.static final int(96) Your LDAP client detected a loop in the referral.static final int(5) Value returned by an LDAP compare operation if the specified attribute and value is not found in the entry (no matching value found).static final int(6) Value returned by an LDAP compare operation if the specified attribute and value is found in the entry (matching value found).static final int(13) [LDAP v3] A secure connection is required for this operation.static final int(91) Your LDAP client failed to connect to the LDAP server.static final int(19) An internal error occurred in the LDAP server.static final int(93) The requested control is not found.static final int(68) The specified entry already exists.static final int(48) The authentication presented to the server is inappropriate.static final int(18) An inappropriate type of matching was used.static final int(61) An index range error occurred.static final int(50) The client is authenticated as a user who does not have the access privileges to perform this operation.static final int(21) The request contains invalid syntax.static final int(49) The credentials presented to the server for authentication are not valid.static final int(34) The specified distinguished name (DN) uses invalid syntax.static final int(35) The specified entry is a "leaf" entry (it has no entries beneath it in the directory tree).static final int(92) The request is not supported by this version of the LDAP protocol.static final int(9) The LDAP server is referring your client to another LDAP server.static final int(85) The operation could not be completed within the maximum time limit.static final int(54) A loop has been detected.static final int(95) More results are being returned from the server.static final int(64) A naming violation has occurred.static final int(94) No results have been returned from the server.static final int(16) The specified attribute could not be found.static final int(32) The entry specified in the request does not exist.static final int(66) The requested operation can only be performed on an entry that has no entries beneath it in the directory tree (in other words, a "leaf" entry).static final int(67) The specified operation cannot be performed on a relative distinguished name (RDN).static final int(69) You cannot modify the specified object class.static final int(65) The requested operation will add or change data so that the data no longer complies with the schema.static final int(1) An internal error occurred in the LDAP server.static final int(80) General result code for other types of errors that may occur.static final int(89) When calling a constructor or method from your client, one or more parameters were incorrectly specified.static final int(2) A LDAP server could not correctly interpret the request sent by your client because the request does not strictly comply with the LDAP protocol.static final int(10) [LDAP v3] The server does not hold the requested entry.static final int(97) The number of sequential referrals (for example, the client may be referred first from LDAP server A to LDAP server B, then from LDAP server B to LDAP server C, and so on) has exceeded the maximum number of referrals (theLDAPConnection.REFERRALS_HOP_LIMIToption).static final int(14) [LDAP v3] While authenticating your client by using a SASL (Simple Authentication Security Layer) mechanism, the server requires the client to send a new SASL bind request (specifying the same SASL mechanism) to continue the authentication process.static final int(81) The LDAP server cannot be contacted.static final int(4) The search found more than the maximum number of results.static final int(60) The "server-side sorting" control was not included with the "virtual list view" control in the search request.static final int(8) A stronger authentication method (more than LDAP_AUTH_SIMPLE) is required by the LDAP server that you are connecting to.static final int(0) The operation completed successfully.static final int(3) The search operation could not be completed within the maximum time limit.static final int(112) The socket factory of the connection is not capable of initiating a TLS session.static final int(52) The LDAP server is unavailable.static final int(12) [LDAP v3] The server received an LDAP v3 control that is marked critical and either (1) is not recognized or supported by the server, or (2) is inappropriate for the operation requested.static final int(17) The specified attribute is not defined.static final int(53) The LDAP server is unable to perform the specified operation. -
Constructor Summary
ConstructorsConstructorDescriptionConstructs a default exception with no specific error information.LDAPReferralException(String message) Constructs a default exception with a specified string as additional information.LDAPReferralException(String message, int resultCode, String serverErrorMessage) Constructs a default exception with a specified string as additional information.LDAPReferralException(String message, int resultCode, String[] referrals) Constructs an exception with a list of LDAP URLs to other LDAP servers. -
Method Summary
Modifier and TypeMethodDescriptionLDAPUrl[]getURLs()Gets the list of referrals (LDAP URLs to other servers) returned by the LDAP server.toString()Gets the string representation of the referral exception, which includes the result code, the message sent back from the LDAP server and the list of referrals.Methods inherited from class LDAPException
errorCodeToString, errorCodeToString, errorCodeToString, errorCodeToString, getLDAPErrorMessage, getLDAPResultCode, getMatchedDNModifier and TypeMethodDescriptionReturns the error message describing the error code (for this exception).static StringerrorCodeToString(int code) Returns the error message describing the specified error code.static StringerrorCodeToString(int code, Locale locale) Returns the error message describing the specified error code.Returns the error message describing the error code for this exception.Returns the error message from the last error, if this message is available (that is, if this message was set).intReturns the result code from the last error that occurred.Returns the maximal subset of a DN which could be matched by the server.Methods inherited from class Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Constructor Details
-
LDAPReferralException
public LDAPReferralException()Constructs a default exception with no specific error information. -
LDAPReferralException
Constructs a default exception with a specified string as additional information. This form is used for lower-level errors.- Parameters:
message- the additional error information
-
LDAPReferralException
Constructs a default exception with a specified string as additional information. This form is used for higher-level LDAP operational errors.- Parameters:
message- the additional error informationresultCode- result codeserverErrorMessage- error message
-
LDAPReferralException
Constructs an exception with a list of LDAP URLs to other LDAP servers. This list of referrals points the client to LDAP servers that may contain the requested entries.- Parameters:
message- the additional error informationresultCode- result codereferrals- array of LDAP URLs identifying other LDAP servers that may contain the requested entries
-
-
Method Details
-
getURLs
Gets the list of referrals (LDAP URLs to other servers) returned by the LDAP server. You can use this list to find the LDAP server that can fulfill your request. If you have set up your search constraints (or theLDAPConnectionobject) to follow referrals automatically, any operation that results in a referral will use this list to create new connections to the LDAP servers in this list.- Returns:
- list of LDAP URLs to other LDAP servers.
-
toString
Gets the string representation of the referral exception, which includes the result code, the message sent back from the LDAP server and the list of referrals.- Overrides:
toStringin classLDAPException- Returns:
- string representation of exception.
- See Also:
-