directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r474487 [3/4] - in /directory/branches/apacheds-schema/shared/ldap/src: main/antlr/ main/java/org/apache/directory/shared/ldap/codec/ main/java/org/apache/directory/shared/ldap/codec/actions/ main/java/org/apache/directory/shared/ldap/codec...
Date Mon, 13 Nov 2006 20:16:19 GMT
Modified: directory/branches/apacheds-schema/shared/ldap/src/main/java/org/apache/directory/shared/ldap/message/ResultCodeEnum.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds-schema/shared/ldap/src/main/java/org/apache/directory/shared/ldap/message/ResultCodeEnum.java?view=diff&rev=474487&r1=474486&r2=474487
==============================================================================
--- directory/branches/apacheds-schema/shared/ldap/src/main/java/org/apache/directory/shared/ldap/message/ResultCodeEnum.java (original)
+++ directory/branches/apacheds-schema/shared/ldap/src/main/java/org/apache/directory/shared/ldap/message/ResultCodeEnum.java Mon Nov 13 12:16:16 2006
@@ -23,12 +23,30 @@
 import java.util.Set;
 import java.util.HashSet;
 import java.util.Collections;
-import java.util.Iterator;
-import javax.naming.*;
-import javax.naming.directory.*;
+
+import javax.naming.AuthenticationException;
+import javax.naming.AuthenticationNotSupportedException;
+import javax.naming.CommunicationException;
+import javax.naming.ContextNotEmptyException;
+import javax.naming.InvalidNameException;
+import javax.naming.LimitExceededException;
+import javax.naming.NameAlreadyBoundException;
+import javax.naming.NameNotFoundException;
+import javax.naming.NamingException;
+import javax.naming.NoPermissionException;
+import javax.naming.OperationNotSupportedException;
+import javax.naming.PartialResultException;
+import javax.naming.ServiceUnavailableException;
+import javax.naming.SizeLimitExceededException;
+import javax.naming.TimeLimitExceededException;
+import javax.naming.directory.AttributeInUseException;
+import javax.naming.directory.InvalidAttributeIdentifierException;
+import javax.naming.directory.InvalidAttributeValueException;
+import javax.naming.directory.InvalidSearchFilterException;
+import javax.naming.directory.NoSuchAttributeException;
+import javax.naming.directory.SchemaViolationException;
 
 import org.apache.directory.shared.ldap.exception.LdapException;
-import org.apache.directory.shared.ldap.util.ValuedEnum;
 
 
 /**
@@ -67,7 +85,7 @@
  *           attributeOrValueExists       (20),
  *           invalidAttributeSyntax       (21),
  *           -- 22-31 unused --
- *           noSuchObject                 (32),
+ *           NO_SUCH_OBJECT                 (32),
  *           aliasProblem                 (33),
  *           invalidDNSyntax              (34),
  *           -- 35 reserved for undefined isLeaf --
@@ -139,106 +157,8 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Revision$
  */
-public class ResultCodeEnum extends ValuedEnum
+public enum ResultCodeEnum
 {
-    static final long serialVersionUID = -6813787847504596968L;
-
-    public static final int SUCCESS_VAL = 0;
-
-    public static final int OPERATIONSERROR_VAL = 1;
-
-    public static final int PROTOCOLERROR_VAL = 2;
-
-    public static final int TIMELIMITEXCEEDED_VAL = 3;
-
-    public static final int SIZELIMITEXCEEDED_VAL = 4;
-
-    public static final int COMPAREFALSE_VAL = 5;
-
-    public static final int COMPARETRUE_VAL = 6;
-
-    public static final int AUTHMETHODNOTSUPPORTED_VAL = 7;
-
-    public static final int STRONGAUTHREQUIRED_VAL = 8;
-
-    public static final int PARTIALRESULTS_VAL = 9;
-
-    public static final int REFERRAL_VAL = 10;
-
-    public static final int ADMINLIMITEXCEEDED_VAL = 11;
-
-    public static final int UNAVAILABLECRITICALEXTENSION_VAL = 12;
-
-    public static final int CONFIDENTIALITYREQUIRED_VAL = 13;
-
-    public static final int SASLBINDINPROGRESS_VAL = 14;
-
-    // -- 15 unused --
-
-    public static final int NOSUCHATTRIBUTE_VAL = 16;
-
-    public static final int UNDEFINEDATTRIBUTETYPE_VAL = 17;
-
-    public static final int INAPPROPRIATEMATCHING_VAL = 18;
-
-    public static final int CONSTRAINTVIOLATION_VAL = 19;
-
-    public static final int ATTRIBUTEORVALUEEXISTS_VAL = 20;
-
-    public static final int INVALIDATTRIBUTESYNTAX_VAL = 21;
-
-    // -- 22-31 unused --
-
-    public static final int NOSUCHOBJECT_VAL = 32;
-
-    public static final int ALIASPROBLEM_VAL = 33;
-
-    public static final int INVALIDDNSYNTAX_VAL = 34;
-
-    // -- 35 reserved for undefined isLeaf --
-
-    public static final int ALIASDEREFERENCINGPROBLEM_VAL = 36;
-
-    // -- 37-47 unused --
-
-    public static final int INAPPROPRIATEAUTHENTICATION_VAL = 48;
-
-    public static final int INVALIDCREDENTIALS_VAL = 49;
-
-    public static final int INSUFFICIENTACCESSRIGHTS_VAL = 50;
-
-    public static final int BUSY_VAL = 51;
-
-    public static final int UNAVAILABLE_VAL = 52;
-
-    public static final int UNWILLINGTOPERFORM_VAL = 53;
-
-    public static final int LOOPDETECT_VAL = 54;
-
-    // -- 55-63 unused --
-
-    public static final int NAMINGVIOLATION_VAL = 64;
-
-    public static final int NOTALLOWEDONNONLEAF_VAL = 66;
-
-    public static final int OBJECTCLASSVIOLATION_VAL = 65;
-
-    public static final int NOTALLOWEDONRDN_VAL = 67;
-
-    public static final int ENTRYALREADYEXISTS_VAL = 68;
-
-    public static final int OBJECTCLASSMODSPROHIBITED_VAL = 69;
-
-    // -- 70 reserved for CLDAP --
-
-    public static final int AFFECTSMULTIPLEDSAS_VAL = 71;
-
-    // -- 72-79 unused --
-
-    public static final int OTHER_VAL = 80;
-
-    // -- 81-90 reserved for APIs --
-
     // ------------------------------------------------------------------------
     // Public Static Constants: Enumeration values and names.
     // ------------------------------------------------------------------------
@@ -254,6 +174,14 @@
     // ------------------------------------------------------------------------
 
     /**
+     * It is returned when the client operation completed successfully without
+     * errors. This code is one of 5 result codes that may be returned in the
+     * LDAPResult which are not used to indicate an error. Applicable
+     * operations: all except for Compare. Result code type: Non-Erroneous
+     */
+    SUCCESS( 0 ),
+
+    /**
      * Servers sends this result code to LDAP v2 clients to refer them to
      * another LDAP server. When sending this code to a client, the server
      * includes a newline-delimited list of LDAP URLs that identify another LDAP
@@ -261,15 +189,7 @@
      * request, servers send an REFERRAL result code instead of this result
      * code.
      */
-    public static final ResultCodeEnum PARTIALRESULTS = new ResultCodeEnum( "PARTIALRESULTS", PARTIALRESULTS_VAL );
-
-    /**
-     * It is returned when the client operation completed successfully without
-     * errors. This code is one of 5 result codes that may be returned in the
-     * LDAPResult which are not used to indicate an error. Applicable
-     * operations: all except for Compare. Result code type: Non-Erroneous
-     */
-    public static final ResultCodeEnum SUCCESS = new ResultCodeEnum( "SUCCESS", SUCCESS_VAL );
+    PARTIAL_RESULTS( 9 ),
 
     /**
      * It is used to indicate that the result of a Compare operation is FALSE
@@ -277,7 +197,7 @@
      * error condition. Applicable operations: Compare. Result code type:
      * Non-Erroneous
      */
-    public static final ResultCodeEnum COMPAREFALSE = new ResultCodeEnum( "COMPAREFALSE", COMPAREFALSE_VAL );
+    COMPARE_FALSE( 5 ),
 
     /**
      * It is used to indicate that the result of a Compare operation is TRUE and
@@ -285,7 +205,7 @@
      * condition. Applicable operations: Compare. Result code type:
      * Non-Erroneous
      */
-    public static final ResultCodeEnum COMPARETRUE = new ResultCodeEnum( "COMPARETRUE", COMPARETRUE_VAL );
+    COMPARE_TRUE( 6 ),
 
     /**
      * Rather than indicating an error, this result code is used to indicate
@@ -297,7 +217,7 @@
      * complete the request. This result code is new in LDAPv3. Applicable
      * operations: all. Result code type: Non-Erroneous
      */
-    public static final ResultCodeEnum REFERRAL = new ResultCodeEnum( "REFERRAL", REFERRAL_VAL );
+    REFERRAL( 10 ),
 
     /**
      * This result code is not an error response from the server, but rather, is
@@ -306,8 +226,7 @@
      * authentication process [RFC2251, Section 4.2.3]. This result code is new
      * in LDAPv3. Applicable operations: Bind. Result code type: Non-Erroneous
      */
-    public static final ResultCodeEnum SASLBINDINPROGRESS = new ResultCodeEnum( "SASLBINDINPROGRESS",
-        SASLBINDINPROGRESS_VAL );
+    SASL_BIND_IN_PROGRESS( 14 ),
 
     // ------------------------------------------------------------------------
     // Problem Specific Error Codes:
@@ -329,8 +248,7 @@
      * the server. Applicable operations: Bind. Result code type: Specific
      * (Security)
      */
-    public static final ResultCodeEnum AUTHMETHODNOTSUPPORTED = new ResultCodeEnum( "AUTHMETHODNOTSUPPORTED",
-        AUTHMETHODNOTSUPPORTED_VAL );
+    AUTH_METHOD_NOT_SUPPORTED( 7 ),
 
     /**
      * This error may be returned on a bind request if the server only accepts
@@ -343,8 +261,7 @@
      * Section 4.4.1] Applicable operations: all. Result code type: Specific
      * (Security)
      */
-    public static final ResultCodeEnum STRONGAUTHREQUIRED = new ResultCodeEnum( "STRONGAUTHREQUIRED",
-        STRONGAUTHREQUIRED_VAL );
+    STRONG_AUTH_REQUIRED( 8 ),
 
     /**
      * This error code may be returned if the session is not protected by a
@@ -356,8 +273,7 @@
      * This error code is new in LDAPv3. Applicable operations: all. Result code
      * type: Specific (Security)
      */
-    public static final ResultCodeEnum CONFIDENTIALITYREQUIRED = new ResultCodeEnum( "CONFIDENTIALITYREQUIRED",
-        CONFIDENTIALITYREQUIRED_VAL );
+    CONFIDENTIALITY_REQUIRED( 13 ),
 
     /**
      * An alias was encountered in a situation where it was not allowed or where
@@ -365,11 +281,10 @@
      * not have read permission for the aliasedObjectName attribute and its
      * value then the error aliasDereferencingProblem should be returned. [X511,
      * Section 7.11.1.1] Notice that this error has similar meaning to
-     * INSUFFICIENTACCESSRIGHTS (50), but is specific to Searching on an alias.
+     * INSUFFICIENT_ACCESS_RIGHTS (50), but is specific to Searching on an alias.
      * Applicable operations: Search. Result code type: Specific (Security)
      */
-    public static final ResultCodeEnum ALIASDEREFERENCINGPROBLEM = new ResultCodeEnum( "ALIASDEREFERENCINGPROBLEM",
-        ALIASDEREFERENCINGPROBLEM_VAL );
+	ALIAS_DEREFERENCING_PROBLEM( 36 ),
 
     /**
      * This error should be returned by the server when the client has tried to
@@ -381,8 +296,7 @@
      * Section 12.7]. Applicable operations: Bind. Result code type: Specific
      * (Security)
      */
-    public static final ResultCodeEnum INAPPROPRIATEAUTHENTICATION = new ResultCodeEnum( "INAPPROPRIATEAUTHENTICATION",
-        INAPPROPRIATEAUTHENTICATION_VAL );
+    INAPPROPRIATE_AUTHENTICATION( 48 ),
 
     /**
      * This error code is returned if the DN or password used in a simple bind
@@ -394,8 +308,7 @@
      * insufficientAccessRights. Applicable operations: Bind. Result code type:
      * Specific (Security)
      */
-    public static final ResultCodeEnum INVALIDCREDENTIALS = new ResultCodeEnum( "INVALIDCREDENTIALS",
-        INVALIDCREDENTIALS_VAL );
+    INVALID_CREDENTIALS( 49 ),
 
     /**
      * The requestor does not have the right to carry out the requested
@@ -404,8 +317,7 @@
      * where the requestor has insufficientAccessRights. Applicable operations:
      * all except for Bind. Result code type: Specific (Security)
      */
-    public static final ResultCodeEnum INSUFFICIENTACCESSRIGHTS = new ResultCodeEnum( "INSUFFICIENTACCESSRIGHTS",
-        INSUFFICIENTACCESSRIGHTS_VAL );
+    INSUFFICIENT_ACCESS_RIGHTS( 50 ),
 
     // ------------------------------------------------------------------------
     // Service Problem Specific Error Codes:
@@ -421,7 +333,7 @@
      * [RFC2251, Section 4.2.1] Applicable operations: all except Bind. Result
      * code type: Specific (Service)
      */
-    public static final ResultCodeEnum OPERATIONSERROR = new ResultCodeEnum( "OPERATIONSERROR", OPERATIONSERROR_VAL );
+    OPERATIONS_ERROR( 1 ),
 
     /**
      * A protocol error should be returned by the server when an invalid or
@@ -437,7 +349,7 @@
      * error in the error string. Applicable operations: all. Result code type:
      * Specific (Service)
      */
-    public static final ResultCodeEnum PROTOCOLERROR = new ResultCodeEnum( "PROTOCOLERROR", PROTOCOLERROR_VAL );
+    PROTOCOL_ERROR( 2 ),
 
     /**
      * This error should be returned when the time to perform an operation has
@@ -454,8 +366,7 @@
      * exceed the defined timelimit. Applicable operations: all. Result code
      * type: Specific (Service)
      */
-    public static final ResultCodeEnum TIMELIMITEXCEEDED = new ResultCodeEnum( "TIMELIMITEXCEEDED",
-        TIMELIMITEXCEEDED_VAL );
+    TIME_LIMIT_EXCEEDED( 3 ),
 
     /**
      * This error should be returned when the number of results generated by a
@@ -465,8 +376,7 @@
      * results, equal in number to the size limit [X511, Section 7.5].
      * Applicable operations: Search. Result code type: Specific (Service)
      */
-    public static final ResultCodeEnum SIZELIMITEXCEEDED = new ResultCodeEnum( "SIZELIMITEXCEEDED",
-        SIZELIMITEXCEEDED_VAL );
+    SIZE_LIMIT_EXCEEDED( 4 ),
 
     /**
      * The server has reached some limit set by an administrative authority, and
@@ -476,8 +386,7 @@
      * candidates [Net]. This error code is new in LDAPv3. Applicable
      * operations: all. Result code type: Specific (Service)
      */
-    public static final ResultCodeEnum ADMINLIMITEXCEEDED = new ResultCodeEnum( "ADMINLIMITEXCEEDED",
-        ADMINLIMITEXCEEDED_VAL );
+    ADMIN_LIMIT_EXCEEDED( 11 ),
 
     /**
      * The server was unable to satisfy the request because one or more critical
@@ -488,8 +397,7 @@
      * code is new in LDAPv3. Applicable operations: all. Result code type:
      * Specific (Service)
      */
-    public static final ResultCodeEnum UNAVAILABLECRITICALEXTENSION = new ResultCodeEnum(
-        "UNAVAILABLECRITICALEXTENSION", UNAVAILABLECRITICALEXTENSION_VAL );
+    UNAVAILABLE_CRITICAL_EXTENSION( 12 ),
 
     /**
      * This error code may be returned if the server is unable to process the
@@ -497,7 +405,7 @@
      * the request shortly the server will be able to process it then.
      * Applicable operations: all. Result code type: Specific (Service)
      */
-    public static final ResultCodeEnum BUSY = new ResultCodeEnum( "BUSY", BUSY_VAL );
+    BUSY( 51 ),
 
     /**
      * This error code is returned when the server is unavailable to process the
@@ -505,7 +413,7 @@
      * down [RFC2251, Section 4.2.3]. Applicable operations: all. Result code
      * type: Specific (Service)
      */
-    public static final ResultCodeEnum UNAVAILABLE = new ResultCodeEnum( "UNAVAILABLE", UNAVAILABLE_VAL );
+    UNAVAILABLE( 52 ),
 
     /**
      * This error code should be returned by the server when a client request is
@@ -521,15 +429,14 @@
      * If appropriate, details of the error should be provided in the error
      * message. Applicable operations: all. Result code type: Specific (Service)
      */
-    public static final ResultCodeEnum UNWILLINGTOPERFORM = new ResultCodeEnum( "UNWILLINGTOPERFORM",
-        UNWILLINGTOPERFORM_VAL );
+    UNWILLING_TO_PERFORM( 53 ),
 
     /**
      * This error may be returned by the server if it detects an alias or
      * referral loop, and is unable to satisfy the client's request. Applicable
      * operations: all. Result code type: Specific (Service)
      */
-    public static final ResultCodeEnum LOOPDETECT = new ResultCodeEnum( "LOOPDETECT", LOOPDETECT_VAL );
+    LOOP_DETECT( 54 ),
 
     // ------------------------------------------------------------------------
     // Attribute Problem Specific Error Codes:
@@ -543,7 +450,7 @@
      * the operation does not exist in the entry. Applicable operations: Modify,
      * Compare. Result code type: Specific (Attribute)
      */
-    public static final ResultCodeEnum NOSUCHATTRIBUTE = new ResultCodeEnum( "NOSUCHATTRIBUTE", NOSUCHATTRIBUTE_VAL );
+    NO_SUCH_ATTRIBUTE( 16 ),
 
     /**
      * This error may be returned if the specified attribute is unrecognized by
@@ -555,16 +462,14 @@
      * Modify operations [X.511, Section 12.4]. Applicable operations: Modify,
      * Add. Result code type: Specific (Attribute)
      */
-    public static final ResultCodeEnum UNDEFINEDATTRIBUTETYPE = new ResultCodeEnum( "UNDEFINEDATTRIBUTETYPE",
-        UNDEFINEDATTRIBUTETYPE_VAL );
+    UNDEFINED_ATTRIBUTE_TYPE( 17 ),
 
     /**
      * An attempt was made, e.g., in a filter, to use a matching rule not
      * defined for the attribute type concerned [X511, Section 12.4]. Applicable
      * operations: Search. Result code type: Specific (Attribute)
      */
-    public static final ResultCodeEnum INAPPROPRIATEMATCHING = new ResultCodeEnum( "INAPPROPRIATEMATCHING",
-        INAPPROPRIATEMATCHING_VAL );
+    INAPPROPRIATE_MATCHING( 18 ),
 
     /**
      * This error should be returned by the server if an attribute value
@@ -573,16 +478,14 @@
      * constraint on the content. Applicable operations: Modify, Add, ModifyDN.
      * Result code type: Specific (Attribute)
      */
-    public static final ResultCodeEnum CONSTRAINTVIOLATION = new ResultCodeEnum( "CONSTRAINTVIOLATION",
-        CONSTRAINTVIOLATION_VAL );
+    CONSTRAINT_VIOLATION( 19 ),
 
     /**
      * This error should be returned by the server if the value specified by the
      * client already exists within the attribute. Applicable operations:
      * Modify, Add. Result code type: Specific (Attribute)
      */
-    public static final ResultCodeEnum ATTRIBUTEORVALUEEXISTS = new ResultCodeEnum( "ATTRIBUTEORVALUEEXISTS",
-        ATTRIBUTEORVALUEEXISTS_VAL );
+    ATTRIBUTE_OR_VALUE_EXISTS( 20 ),
 
     /**
      * This error should be returned by the server if the attribute syntax for
@@ -590,8 +493,7 @@
      * unrecognized or invalid. Applicable operations: Modify, Add. Result code
      * type: Specific (Attribute)
      */
-    public static final ResultCodeEnum INVALIDATTRIBUTESYNTAX = new ResultCodeEnum( "INVALIDATTRIBUTESYNTAX",
-        INVALIDATTRIBUTESYNTAX_VAL );
+    INVALID_ATTRIBUTE_SYNTAX( 21 ),
 
     // ------------------------------------------------------------------------
     // Name Problem Specific Error Codes:
@@ -599,7 +501,7 @@
     // A name error reports a problem related to the distinguished name
     // provided as an argument to an operation [X511, Section 12.5].
     //
-    // For result codes of noSuchObject, aliasProblem, invalidDNSyntax and
+    // For result codes of NO_SUCH_OBJECT, aliasProblem, invalidDNSyntax and
     // aliasDereferencingProblem (see Section 5.2.2.3.7), the matchedDN
     // field is set to the name of the lowest entry (object or alias) in the
     // directory that was matched. If no aliases were dereferenced while
@@ -613,21 +515,21 @@
     /**
      * This error should only be returned if the target object cannot be found.
      * For example, in a search operation if the search base can not be located
-     * in the DSA the server should return noSuchObject. If, however, the search
+     * in the DSA the server should return NO_SUCH_OBJECT. If, however, the search
      * base is found but does not match the search filter, success, with no
-     * resultant objects, should be returned instead of noSuchObject. If the
-     * LDAP server is a front end for an X.500 DSA then noSuchObject may also be
+     * resultant objects, should be returned instead of NO_SUCH_OBJECT. If the
+     * LDAP server is a front end for an X.500 DSA then NO_SUCH_OBJECT may also be
      * returned if discloseOnError is not granted for an entry and the client
      * does not have permission to view or modify the entry. Applicable
      * operations: all except for Bind. Result code type: Specific (Name)
      */
-    public static final ResultCodeEnum NOSUCHOBJECT = new ResultCodeEnum( "NOSUCHOBJECT", NOSUCHOBJECT_VAL );
+    NO_SUCH_OBJECT( 32 ),
 
     /**
      * An alias has been dereferenced which names no object [X511, Section 12.5]
      * Applicable operations: Search. Result code type: Specific (Name)
      */
-    public static final ResultCodeEnum ALIASPROBLEM = new ResultCodeEnum( "ALIASPROBLEM", ALIASPROBLEM_VAL );
+    ALIAS_PROBLEM( 33 ),
 
     /**
      * This error should be returned by the server if the DN syntax is
@@ -636,8 +538,8 @@
      * DSA ; in this case namingViolation should be returned instead. Applicable
      * operations: all. Result code type: Specific (Name)
      */
-    public static final ResultCodeEnum INVALIDDNSYNTAX = new ResultCodeEnum( "INVALIDDNSYNTAX", INVALIDDNSYNTAX_VAL );
-
+    INVALID_DN_SYNTAX( 34 ),
+    
     // ------------------------------------------------------------------------
     // Update Problem Specific Error Codes:
     //
@@ -654,7 +556,7 @@
      * 12.9]. Applicable operations: Add, ModifyDN. Result code type: Specific
      * (Update)
      */
-    public static final ResultCodeEnum NAMINGVIOLATION = new ResultCodeEnum( "NAMINGVIOLATION", NAMINGVIOLATION_VAL );
+    NAMING_VIOLATION( 64 ),
 
     /**
      * This error should be returned if the operation requested by the user
@@ -668,8 +570,7 @@
      * permits are still present. Applicable operations: Add, Modify, ModifyDN.
      * Result code type: Specific (Update)
      */
-    public static final ResultCodeEnum OBJECTCLASSVIOLATION = new ResultCodeEnum( "OBJECTCLASSVIOLATION",
-        OBJECTCLASSVIOLATION_VAL );
+    OBJECT_CLASS_VIOLATION( 65 ),
 
     /**
      * This error should be returned if the client attempts to perform an
@@ -681,8 +582,7 @@
      * [X.511, Section 11.4.1]). Applicable operations: Delete, ModifyDN. Result
      * code type: Specific (Update)
      */
-    public static final ResultCodeEnum NOTALLOWEDONNONLEAF = new ResultCodeEnum( "NOTALLOWEDONNONLEAF",
-        NOTALLOWEDONNONLEAF_VAL );
+    NOT_ALLOWED_ON_NON_LEAF( 66 ),
 
     /**
      * The attempted operation would affect the RDN (e.g., removal of an
@@ -692,7 +592,7 @@
      * should return the error notAllowedOnRDN. [RFC2251, Section 4.6]
      * Applicable operations: Modify. Result code type: Specific (Update)
      */
-    public static final ResultCodeEnum NOTALLOWEDONRDN = new ResultCodeEnum( "NOTALLOWEDONRDN", NOTALLOWEDONRDN_VAL );
+    NOT_ALLOWED_ON_RDN( 67 ),
 
     /**
      * This error should be returned by the server when the client attempts to
@@ -700,8 +600,7 @@
      * entry with the name of an entry which exists. Applicable operations: Add,
      * ModifyDN. Result code type: Specific (Update)
      */
-    public static final ResultCodeEnum ENTRYALREADYEXISTS = new ResultCodeEnum( "ENTRYALREADYEXISTS",
-        ENTRYALREADYEXISTS_VAL );
+    ENTRY_ALREADY_EXISTS( 68 ),
 
     /**
      * An operation attempted to modify an object class that should not be
@@ -711,8 +610,7 @@
      * forms, structure rules etc. [X.511, Section 12.9]. Applicable operations:
      * Modify. Result code type: Specific (Update)
      */
-    public static final ResultCodeEnum OBJECTCLASSMODSPROHIBITED = new ResultCodeEnum( "OBJECTCLASSMODSPROHIBITE",
-        OBJECTCLASSMODSPROHIBITED_VAL );
+    OBJECT_CLASS_MODS_PROHIBITED( 69 ),
 
     /**
      * This error code should be returned to indicate that the operation could
@@ -725,8 +623,7 @@
      * entries and subtrees between servers [RFC2251, Section 4.9]. Applicable
      * operations: ModifyDN. Result code type: Specific (Update)
      */
-    public static final ResultCodeEnum AFFECTSMULTIPLEDSAS = new ResultCodeEnum( "AFFECTSMULTIPLEDSAS",
-        AFFECTSMULTIPLEDSAS_VAL );
+    AFFECTS_MULTIPLE_DSAS( 71 ),
 
     // ------------------------------------------------------------------------
     // General Error Codes:
@@ -743,8 +640,30 @@
      * of the error should be provided in the error message. Applicable
      * operations: all. Result code type: General
      */
-    public static final ResultCodeEnum OTHER = new ResultCodeEnum( "OTHER", OTHER_VAL );
+    OTHER( 80 );
+
+    
+    // -- 15 unused --
+
+    // -- 22-31 unused --
+
+    // -- 35 reserved for undefined isLeaf --
+
+    // -- 37-47 unused --
+
+    // -- 55-63 unused --
+
+    // -- 70 reserved for CLDAP --
 
+    // -- 72-79 unused --
+
+    // -- 81-90 reserved for APIs --
+
+	private int resultCode;
+	
+	public static final Set<ResultCodeEnum> EMPTY_RESULT_CODE_SET = new HashSet<ResultCodeEnum>();
+	
+	
     // ------------------------------------------------------------------------
     // Error Codes Grouped Into Categories & Static Accessors
     // ------------------------------------------------------------------------
@@ -763,7 +682,7 @@
      * <li><a href="OTHER">OTHER</a></li>
      * </ul>
      */
-    public static final Set GENERAL_CODES = Collections.singleton( OTHER );
+    public static final Set<ResultCodeEnum> GENERAL_CODES = Collections.singleton( OTHER );
 
     /**
      * Five result codes that may be returned in LDAPResult are not used to
@@ -776,18 +695,18 @@
      * <li><a href="#COMPARETRUE">COMPARETRUE</a></li>
      * <li><a href="#COMPAREFALSE">COMPAREFALSE</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#SASLBINDINPROGRESS">SASLBINDINPROGRESS</a></li>
+     * <li><a href="#SASL_BIND_IN_PROGRESS">SASL_BIND_IN_PROGRESS</a></li>
      * </ul>
      */
-    public static final Set NON_ERRONEOUS_CODES;
+    public static final Set<ResultCodeEnum> NON_ERRONEOUS_CODES;
     static
     {
-        HashSet set = new HashSet();
-        set.add( SUCCESS );
-        set.add( COMPARETRUE );
-        set.add( COMPAREFALSE );
-        set.add( REFERRAL );
-        set.add( SASLBINDINPROGRESS );
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.COMPARE_TRUE );
+        set.add( ResultCodeEnum.COMPARE_FALSE );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.SASL_BIND_IN_PROGRESS );
         NON_ERRONEOUS_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -796,24 +715,24 @@
      * attribute error reports a problem related to an attribute specified by
      * the client in their request message. The set contains:
      * <ul>
-     * <li><a href="#NOSUCHATTRIBUTE">NOSUCHATTRIBUTE</a></li>
-     * <li><a href="#UNDEFINEDATTRIBUTETYPE">UNDEFINEDATTRIBUTETYPE</a></li>
-     * <li><a href="#INAPPROPRIATEMATCHING">INAPPROPRIATEMATCHING</a></li>
-     * <li><a href="#CONSTRAINTVIOLATION">CONSTRAINTVIOLATION</a></li>
-     * <li><a href="#ATTRIBUTEORVALUEEXISTS">ATTRIBUTEORVALUEEXISTS</a></li>
-     * <li><a href="#INVALIDATTRIBUTESYNTAX">INVALIDATTRIBUTESYNTAX</a></li>
-     * </ul>
-     */
-    public static final Set ATTRIBUTE_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( NOSUCHATTRIBUTE );
-        set.add( UNDEFINEDATTRIBUTETYPE );
-        set.add( INAPPROPRIATEMATCHING );
-        set.add( CONSTRAINTVIOLATION );
-        set.add( ATTRIBUTEORVALUEEXISTS );
-        set.add( INVALIDATTRIBUTESYNTAX );
+     * <li><a href="#NO_SUCH_ATTRIBUTE">NO_SUCH_ATTRIBUTE</a></li>
+     * <li><a href="#UNDEFINED_ATTRIBUTE_TYPE">UNDEFINED_ATTRIBUTE_TYPE</a></li>
+     * <li><a href="#INAPPROPRIATE_MATCHING">INAPPROPRIATE_MATCHING</a></li>
+     * <li><a href="#CONSTRAINT_VIOLATION">CONSTRAINT_VIOLATION</a></li>
+     * <li><a href="#ATTRIBUTE_OR_VALUE_EXISTS">ATTRIBUTE_OR_VALUE_EXISTS</a></li>
+     * <li><a href="#INVALID_ATTRIBUTE_SYNTAX">INVALID_ATTRIBUTE_SYNTAX</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> ATTRIBUTE_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.NO_SUCH_ATTRIBUTE );
+        set.add( ResultCodeEnum.UNDEFINED_ATTRIBUTE_TYPE );
+        set.add( ResultCodeEnum.INAPPROPRIATE_MATCHING );
+        set.add( ResultCodeEnum.CONSTRAINT_VIOLATION );
+        set.add( ResultCodeEnum.ATTRIBUTE_OR_VALUE_EXISTS );
+        set.add( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX );
         ATTRIBUTE_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -821,7 +740,7 @@
      * Stores the set of error codes associated with name problems. A name error
      * reports a problem related to the distinguished name provided as an
      * argument to an operation [X511, Section 12.5]. For result codes of
-     * noSuchObject, aliasProblem, invalidDNSyntax and
+     * NO_SUCH_OBJECT, aliasProblem, invalidDNSyntax and
      * aliasDereferencingProblem, the matchedDN field is set to the name of the
      * lowest entry (object or alias) in the directory that was matched. If no
      * aliases were dereferenced while attempting to locate the entry, this will
@@ -830,18 +749,18 @@
      * matchedDN field is to be set to a zero length string with all other
      * result codes [RFC2251, Section 4.1.10]. The set contains:
      * <ul>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#ALIASPROBLEM">ALIASPROBLEM</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#ALIAS_PROBLEM">ALIAS_PROBLEM</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
      * </ul>
      */
-    public static final Set NAME_CODES;
+    public static final Set<ResultCodeEnum> NAME_CODES;
     static
     {
-        HashSet set = new HashSet();
-        set.add( NOSUCHOBJECT );
-        set.add( ALIASPROBLEM );
-        set.add( INVALIDDNSYNTAX );
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.ALIAS_PROBLEM );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
         NAME_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -850,26 +769,26 @@
      * security error reports a problem in carrying out an operation for
      * security reasons [X511, Section 12.7]. The set contains:
      * <ul>
-     * <li><a href="#INVALIDCREDENTIALS">INVALIDCREDENTIALS</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#AUTHMETHODNOTSUPPORTED">AUTHMETHODNOTSUPPORTED</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
-     * <li><a href="#ALIASDEREFERENCINGPROBLEM">ALIASDEREFERENCINGPROBLEM</a></li>
-     * <li><a href="#INAPPROPRIATEAUTHENTICATION">INAPPROPRIATEAUTHENTICATION</a></li>
-     * </ul>
-     */
-    public static final Set SECURITY_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( INVALIDCREDENTIALS );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( AUTHMETHODNOTSUPPORTED );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( ALIASDEREFERENCINGPROBLEM );
-        set.add( INAPPROPRIATEAUTHENTICATION );
+     * <li><a href="#INVALID_CREDENTIALS">INVALID_CREDENTIALS</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#AUTH_METHOD_NOT_SUPPORTED">AUTH_METHOD_NOT_SUPPORTED</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
+     * <li><a href="#ALIAS_DEREFERENCING_PROBLEM">ALIAS_DEREFERENCING_PROBLEM</a></li>
+     * <li><a href="#INAPPROPRIATE_AUTHENTICATION">INAPPROPRIATE_AUTHENTICATION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> SECURITY_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.INVALID_CREDENTIALS );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.AUTH_METHOD_NOT_SUPPORTED );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.ALIAS_DEREFERENCING_PROBLEM );
+        set.add( ResultCodeEnum.INAPPROPRIATE_AUTHENTICATION );
         SECURITY_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -879,31 +798,31 @@
      * problems. The set contains:
      * <ul>
      * <li><a href="#BUSY">BUSY</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
      * <li><a href="#OPERATIONSERROR">OPERATIONSERROR</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#SIZELIMITEXCEEDED">SIZELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set SERVICE_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( PROTOCOLERROR );
-        set.add( OPERATIONSERROR );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( SIZELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#SIZE_LIMIT_EXCEEDED">SIZE_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> SERVICE_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.OPERATIONS_ERROR );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.SIZE_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         SERVICE_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -912,26 +831,26 @@
      * modify information in the DIB [X511, Section 12.9]. This set contains the
      * category of update errors.
      * <ul>
-     * <li><a href="#NAMINGVIOLATION">NAMINGVIOLATION</a></li>
-     * <li><a href="#OBJECTCLASSVIOLATION">OBJECTCLASSVIOLATION</a></li>
-     * <li><a href="#NOTALLOWEDONNONLEAF">NOTALLOWEDONNONLEAF</a></li>
-     * <li><a href="#NOTALLOWEDONRDN">NOTALLOWEDONRDN</a></li>
-     * <li><a href="#ENTRYALREADYEXISTS">ENTRYALREADYEXISTS</a></li>
-     * <li><a href="#OBJECTCLASSMODSPROHIBITED">OBJECTCLASSMODSPROHIBITED</a></li>
-     * <li><a href="#AFFECTSMULTIPLEDSAS">AFFECTSMULTIPLEDSAS</a></li>
-     * </ul>
-     */
-    public static final Set UPDATE_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( NAMINGVIOLATION );
-        set.add( OBJECTCLASSVIOLATION );
-        set.add( NOTALLOWEDONNONLEAF );
-        set.add( NOTALLOWEDONRDN );
-        set.add( ENTRYALREADYEXISTS );
-        set.add( OBJECTCLASSMODSPROHIBITED );
-        set.add( AFFECTSMULTIPLEDSAS );
+     * <li><a href="#NAMING_VIOLATION">NAMING_VIOLATION</a></li>
+     * <li><a href="#OBJECT_CLASS_VIOLATION">OBJECT_CLASS_VIOLATION</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_NON_LEAF">NOT_ALLOWED_ON_NON_LEAF</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_RDN">NOT_ALLOWED_ON_RDN</a></li>
+     * <li><a href="#ENTRY_ALREADY_EXISTS">ENTRY_ALREADY_EXISTS</a></li>
+     * <li><a href="#OBJECT_CLASS_MODS_PROHIBITED">OBJECT_CLASS_MODS_PROHIBITED</a></li>
+     * <li><a href="#AFFECTS_MULTIPLE_DSAS">AFFECTS_MULTIPLE_DSAS</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> UPDATE_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.NAMING_VIOLATION );
+        set.add( ResultCodeEnum.OBJECT_CLASS_VIOLATION );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_NON_LEAF );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_RDN );
+        set.add( ResultCodeEnum.ENTRY_ALREADY_EXISTS );
+        set.add( ResultCodeEnum.OBJECT_CLASS_MODS_PROHIBITED );
+        set.add( ResultCodeEnum.AFFECTS_MULTIPLE_DSAS );
         UPDATE_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -946,33 +865,33 @@
      * <li><a href="#BUSY">BUSY</a></li>
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set COMMON_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( PROTOCOLERROR );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> COMMON_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         COMMON_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -984,44 +903,44 @@
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#SASLBINDINPROGRESS">SASLBINDINPROGRESS</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#INVALIDCREDENTIALS">INVALIDCREDENTIALS</a></li>
-     * <li><a href="#AUTHMETHODNOTSUPPORTED">AUTHMETHODNOTSUPPORTED</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INAPPROPRIATEAUTHENTICATION">INAPPROPRIATEAUTHENTICATION</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set BIND_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( SUCCESS );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( PROTOCOLERROR );
-        set.add( INVALIDDNSYNTAX );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( SASLBINDINPROGRESS );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( INVALIDCREDENTIALS );
-        set.add( AUTHMETHODNOTSUPPORTED );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INAPPROPRIATEAUTHENTICATION );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#SASL_BIND_IN_PROGRESS">SASL_BIND_IN_PROGRESS</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#INVALID_CREDENTIALS">INVALID_CREDENTIALS</a></li>
+     * <li><a href="#AUTH_METHOD_NOT_SUPPORTED">AUTH_METHOD_NOT_SUPPORTED</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INAPPROPRIATE_AUTHENTICATION">INAPPROPRIATE_AUTHENTICATION</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> BIND_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.SASL_BIND_IN_PROGRESS );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.INVALID_CREDENTIALS );
+        set.add( ResultCodeEnum.AUTH_METHOD_NOT_SUPPORTED );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INAPPROPRIATE_AUTHENTICATION );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         BIND_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -1033,48 +952,48 @@
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#ALIASPROBLEM">ALIASPROBLEM</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#SIZELIMITEXCEEDED">SIZELIMITEXCEEDED</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#INAPPROPRIATEMATCHING">INAPPROPRIATEMATCHING</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
-     * <li><a href="#ALIASDEREFERENCINGPROBLEM">ALIASDEREFERENCINGPROBLEM</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set SEARCH_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( SUCCESS );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( NOSUCHOBJECT );
-        set.add( ALIASPROBLEM );
-        set.add( PROTOCOLERROR );
-        set.add( INVALIDDNSYNTAX );
-        set.add( SIZELIMITEXCEEDED );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( INAPPROPRIATEMATCHING );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( ALIASDEREFERENCINGPROBLEM );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#ALIAS_PROBLEM">ALIAS_PROBLEM</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#SIZE_LIMIT_EXCEEDED">SIZE_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#INAPPROPRIATE_MATCHING">INAPPROPRIATE_MATCHING</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
+     * <li><a href="#ALIAS_DEREFERENCING_PROBLEM">ALIAS_DEREFERENCING_PROBLEM</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> SEARCH_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.ALIAS_PROBLEM );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.SIZE_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.INAPPROPRIATE_MATCHING );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.ALIAS_DEREFERENCING_PROBLEM );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         SEARCH_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -1086,56 +1005,56 @@
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#NOTALLOWEDONRDN">NOTALLOWEDONRDN</a></li>
-     * <li><a href="#NOSUCHATTRIBUTE">NOSUCHATTRIBUTE</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#CONSTRAINTVIOLATION">CONSTRAINTVIOLATION</a></li>
-     * <li><a href="#OBJECTCLASSVIOLATION">OBJECTCLASSVIOLATION</a></li>
-     * <li><a href="#INVALIDATTRIBUTESYNTAX">INVALIDATTRIBUTESYNTAX</a></li>
-     * <li><a href="#UNDEFINEDATTRIBUTETYPE">UNDEFINEDATTRIBUTETYPE</a></li>
-     * <li><a href="#ATTRIBUTEORVALUEEXISTS">ATTRIBUTEORVALUEEXISTS</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
-     * <li><a href="#OBJECTCLASSMODSPROHIBITED">OBJECTCLASSMODSPROHIBITED</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set MODIFY_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( SUCCESS );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( NOSUCHOBJECT );
-        set.add( PROTOCOLERROR );
-        set.add( INVALIDDNSYNTAX );
-        set.add( NOTALLOWEDONRDN );
-        set.add( NOSUCHATTRIBUTE );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( CONSTRAINTVIOLATION );
-        set.add( OBJECTCLASSVIOLATION );
-        set.add( INVALIDATTRIBUTESYNTAX );
-        set.add( UNDEFINEDATTRIBUTETYPE );
-        set.add( ATTRIBUTEORVALUEEXISTS );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( OBJECTCLASSMODSPROHIBITED );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_RDN">NOT_ALLOWED_ON_RDN</a></li>
+     * <li><a href="#NO_SUCH_ATTRIBUTE">NO_SUCH_ATTRIBUTE</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#CONSTRAINT_VIOLATION">CONSTRAINT_VIOLATION</a></li>
+     * <li><a href="#OBJECT_CLASS_VIOLATION">OBJECT_CLASS_VIOLATION</a></li>
+     * <li><a href="#INVALID_ATTRIBUTE_SYNTAX">INVALID_ATTRIBUTE_SYNTAX</a></li>
+     * <li><a href="#UNDEFINED_ATTRIBUTE_TYPE">UNDEFINED_ATTRIBUTE_TYPE</a></li>
+     * <li><a href="#ATTRIBUTE_OR_VALUE_EXISTS">ATTRIBUTE_OR_VALUE_EXISTS</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
+     * <li><a href="#OBJECT_CLASS_MODS_PROHIBITED">OBJECT_CLASS_MODS_PROHIBITED</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> MODIFY_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_RDN );
+        set.add( ResultCodeEnum.NO_SUCH_ATTRIBUTE );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.CONSTRAINT_VIOLATION );
+        set.add( ResultCodeEnum.OBJECT_CLASS_VIOLATION );
+        set.add( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX );
+        set.add( ResultCodeEnum.UNDEFINED_ATTRIBUTE_TYPE );
+        set.add( ResultCodeEnum.ATTRIBUTE_OR_VALUE_EXISTS );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.OBJECT_CLASS_MODS_PROHIBITED );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         MODIFY_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -1147,54 +1066,54 @@
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#NAMINGVIOLATION">NAMINGVIOLATION</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#ENTRYALREADYEXISTS">ENTRYALREADYEXISTS</a></li>
-     * <li><a href="#CONSTRAINTVIOLATION">CONSTRAINTVIOLATION</a></li>
-     * <li><a href="#OBJECTCLASSVIOLATION">OBJECTCLASSVIOLATION</a></li>
-     * <li><a href="#INVALIDATTRIBUTESYNTAX">INVALIDATTRIBUTESYNTAX</a></li>
-     * <li><a href="#ATTRIBUTEORVALUEEXISTS">ATTRIBUTEORVALUEEXISTS</a></li>
-     * <li><a href="#UNDEFINEDATTRIBUTETYPE">UNDEFINEDATTRIBUTETYPE</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set ADD_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( SUCCESS );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( NOSUCHOBJECT );
-        set.add( PROTOCOLERROR );
-        set.add( NAMINGVIOLATION );
-        set.add( INVALIDDNSYNTAX );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( ENTRYALREADYEXISTS );
-        set.add( CONSTRAINTVIOLATION );
-        set.add( OBJECTCLASSVIOLATION );
-        set.add( INVALIDATTRIBUTESYNTAX );
-        set.add( ATTRIBUTEORVALUEEXISTS );
-        set.add( UNDEFINEDATTRIBUTETYPE );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#NAMING_VIOLATION">NAMING_VIOLATION</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#ENTRY_ALREADY_EXISTS">ENTRY_ALREADY_EXISTS</a></li>
+     * <li><a href="#CONSTRAINT_VIOLATION">CONSTRAINT_VIOLATION</a></li>
+     * <li><a href="#OBJECT_CLASS_VIOLATION">OBJECT_CLASS_VIOLATION</a></li>
+     * <li><a href="#INVALID_ATTRIBUTE_SYNTAX">INVALID_ATTRIBUTE_SYNTAX</a></li>
+     * <li><a href="#ATTRIBUTE_OR_VALUE_EXISTS">ATTRIBUTE_OR_VALUE_EXISTS</a></li>
+     * <li><a href="#UNDEFINED_ATTRIBUTE_TYPE">UNDEFINED_ATTRIBUTE_TYPE</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> ADD_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.NAMING_VIOLATION );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.ENTRY_ALREADY_EXISTS );
+        set.add( ResultCodeEnum.CONSTRAINT_VIOLATION );
+        set.add( ResultCodeEnum.OBJECT_CLASS_VIOLATION );
+        set.add( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX );
+        set.add( ResultCodeEnum.ATTRIBUTE_OR_VALUE_EXISTS );
+        set.add( ResultCodeEnum.UNDEFINED_ATTRIBUTE_TYPE );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         ADD_CODES = Collections.unmodifiableSet( set );
     };
 
@@ -1206,42 +1125,42 @@
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#NOTALLOWEDONNONLEAF">NOTALLOWEDONNONLEAF</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set DELETE_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( SUCCESS );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( NOSUCHOBJECT );
-        set.add( PROTOCOLERROR );
-        set.add( INVALIDDNSYNTAX );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( NOTALLOWEDONNONLEAF );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_NON_LEAF">NOT_ALLOWED_ON_NON_LEAF</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> DELETE_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_NON_LEAF );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         DELETE_CODES = Collections.unmodifiableSet( set );
     };
 
@@ -1253,52 +1172,52 @@
      * <li><a href="#OTHER">OTHER</a></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#NAMINGVIOLATION">NAMINGVIOLATION</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#ENTRYALREADYEXISTS">ENTRYALREADYEXISTS</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#NOTALLOWEDONNONLEAF">NOTALLOWEDONNONLEAF</a></li>
-     * <li><a href="#AFFECTSMULTIPLEDSAS">AFFECTSMULTIPLEDSAS</a></li>
-     * <li><a href="#CONSTRAINTVIOLATION">CONSTRAINTVIOLATION</a></li>
-     * <li><a href="#OBJECTCLASSVIOLATION">OBJECTCLASSVIOLATION</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * </ul>
-     */
-    public static final Set MODIFYDN_CODES;
-    static
-    {
-        HashSet set = new HashSet();
-        set.add( BUSY );
-        set.add( OTHER );
-        set.add( SUCCESS );
-        set.add( REFERRAL );
-        set.add( LOOPDETECT );
-        set.add( UNAVAILABLE );
-        set.add( NOSUCHOBJECT );
-        set.add( PROTOCOLERROR );
-        set.add( INVALIDDNSYNTAX );
-        set.add( NAMINGVIOLATION );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( ENTRYALREADYEXISTS );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( NOTALLOWEDONNONLEAF );
-        set.add( AFFECTSMULTIPLEDSAS );
-        set.add( CONSTRAINTVIOLATION );
-        set.add( OBJECTCLASSVIOLATION );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( UNAVAILABLECRITICALEXTENSION );
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#NAMING_VIOLATION">NAMING_VIOLATION</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#ENTRY_ALREADY_EXISTS">ENTRY_ALREADY_EXISTS</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_NON_LEAF">NOT_ALLOWED_ON_NON_LEAF</a></li>
+     * <li><a href="#AFFECTS_MULTIPLE_DSAS">AFFECTS_MULTIPLE_DSAS</a></li>
+     * <li><a href="#CONSTRAINT_VIOLATION">CONSTRAINT_VIOLATION</a></li>
+     * <li><a href="#OBJECT_CLASS_VIOLATION">OBJECT_CLASS_VIOLATION</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * </ul>
+     */
+    public static final Set<ResultCodeEnum> MODIFYDN_CODES;
+    static
+    {
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.OTHER );
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.NAMING_VIOLATION );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.ENTRY_ALREADY_EXISTS );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_NON_LEAF );
+        set.add( ResultCodeEnum.AFFECTS_MULTIPLE_DSAS );
+        set.add( ResultCodeEnum.CONSTRAINT_VIOLATION );
+        set.add( ResultCodeEnum.OBJECT_CLASS_VIOLATION );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
         MODIFYDN_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -1307,51 +1226,51 @@
      * operations. The set contains:
      * <ul>
      * <li><a href="#OPERATIONSERROR">OPERATIONSERROR</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
      * <li><a href="#COMPAREFALSE">COMPAREFALSE</a></li>
      * <li><a href="#COMPARETRUE">COMPARETRUE</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#NOSUCHATTRIBUTE">NOSUCHATTRIBUTE</a></li>
-     * <li><a href="#INVALIDATTRIBUTESYNTAX">INVALIDATTRIBUTESYNTAX</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#NO_SUCH_ATTRIBUTE">NO_SUCH_ATTRIBUTE</a></li>
+     * <li><a href="#INVALID_ATTRIBUTE_SYNTAX">INVALID_ATTRIBUTE_SYNTAX</a></li>
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
      * <li><a href="#BUSY">BUSY</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
      * <li><a href="#OTHER">OTHER</a></li>
      * </ul>
      */
-    public static final Set COMPARE_CODES;
+    public static final Set<ResultCodeEnum> COMPARE_CODES;
     static
     {
-        HashSet set = new HashSet();
-        set.add( OPERATIONSERROR );
-        set.add( PROTOCOLERROR );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( COMPAREFALSE );
-        set.add( COMPARETRUE );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( UNAVAILABLECRITICALEXTENSION );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( NOSUCHATTRIBUTE );
-        set.add( INVALIDATTRIBUTESYNTAX );
-        set.add( NOSUCHOBJECT );
-        set.add( INVALIDDNSYNTAX );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( BUSY );
-        set.add( UNAVAILABLE );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( LOOPDETECT );
-        set.add( REFERRAL );
-        set.add( OTHER );
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.OPERATIONS_ERROR );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.COMPARE_FALSE );
+        set.add( ResultCodeEnum.COMPARE_TRUE );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.NO_SUCH_ATTRIBUTE );
+        set.add( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.OTHER );
         COMPARE_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -1362,88 +1281,88 @@
      * <li></li>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#OPERATIONSERROR">OPERATIONSERROR</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#SIZELIMITEXCEEDED">SIZELIMITEXCEEDED</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#SIZE_LIMIT_EXCEEDED">SIZE_LIMIT_EXCEEDED</a></li>
      * <li><a href="#COMPAREFALSE">COMPAREFALSE</a></li>
      * <li><a href="#COMPARETRUE">COMPARETRUE</a></li>
-     * <li><a href="#AUTHMETHODNOTSUPPORTED">AUTHMETHODNOTSUPPORTED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
+     * <li><a href="#AUTH_METHOD_NOT_SUPPORTED">AUTH_METHOD_NOT_SUPPORTED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#SASLBINDINPROGRESS">SASLBINDINPROGRESS</a></li>
-     * <li><a href="#NOSUCHATTRIBUTE">NOSUCHATTRIBUTE</a></li>
-     * <li><a href="#UNDEFINEDATTRIBUTETYPE">UNDEFINEDATTRIBUTETYPE</a></li>
-     * <li><a href="#INAPPROPRIATEMATCHING">INAPPROPRIATEMATCHING</a></li>
-     * <li><a href="#CONSTRAINTVIOLATION">CONSTRAINTVIOLATION</a></li>
-     * <li><a href="#ATTRIBUTEORVALUEEXISTS">ATTRIBUTEORVALUEEXISTS</a></li>
-     * <li><a href="#INVALIDATTRIBUTESYNTAX">INVALIDATTRIBUTESYNTAX</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#ALIASPROBLEM">ALIASPROBLEM</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#ALIASDEREFERENCINGPROBLEM">ALIASDEREFERENCINGPROBLEM</a></li>
-     * <li><a href="#INAPPROPRIATEAUTHENTICATION">INAPPROPRIATEAUTHENTICATION</a></li>
-     * <li><a href="#INVALIDCREDENTIALS">INVALIDCREDENTIALS</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#SASL_BIND_IN_PROGRESS">SASL_BIND_IN_PROGRESS</a></li>
+     * <li><a href="#NO_SUCH_ATTRIBUTE">NO_SUCH_ATTRIBUTE</a></li>
+     * <li><a href="#UNDEFINED_ATTRIBUTE_TYPE">UNDEFINED_ATTRIBUTE_TYPE</a></li>
+     * <li><a href="#INAPPROPRIATE_MATCHING">INAPPROPRIATE_MATCHING</a></li>
+     * <li><a href="#CONSTRAINT_VIOLATION">CONSTRAINT_VIOLATION</a></li>
+     * <li><a href="#ATTRIBUTE_OR_VALUE_EXISTS">ATTRIBUTE_OR_VALUE_EXISTS</a></li>
+     * <li><a href="#INVALID_ATTRIBUTE_SYNTAX">INVALID_ATTRIBUTE_SYNTAX</a></li>
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#ALIAS_PROBLEM">ALIAS_PROBLEM</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#ALIAS_DEREFERENCING_PROBLEM">ALIAS_DEREFERENCING_PROBLEM</a></li>
+     * <li><a href="#INAPPROPRIATE_AUTHENTICATION">INAPPROPRIATE_AUTHENTICATION</a></li>
+     * <li><a href="#INVALID_CREDENTIALS">INVALID_CREDENTIALS</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
      * <li><a href="#BUSY">BUSY</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
-     * <li><a href="#NAMINGVIOLATION">NAMINGVIOLATION</a></li>
-     * <li><a href="#OBJECTCLASSVIOLATION">OBJECTCLASSVIOLATION</a></li>
-     * <li><a href="#NOTALLOWEDONNONLEAF">NOTALLOWEDONNONLEAF</a></li>
-     * <li><a href="#NOTALLOWEDONRDN">NOTALLOWEDONRDN</a></li>
-     * <li><a href="#ENTRYALREADYEXISTS">ENTRYALREADYEXISTS</a></li>
-     * <li><a href="#OBJECTCLASSMODSPROHIBITED">OBJECTCLASSMODSPROHIBITED</a></li>
-     * <li><a href="#AFFECTSMULTIPLEDSAS">AFFECTSMULTIPLEDSAS</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
+     * <li><a href="#NAMING_VIOLATION">NAMING_VIOLATION</a></li>
+     * <li><a href="#OBJECT_CLASS_VIOLATION">OBJECT_CLASS_VIOLATION</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_NON_LEAF">NOT_ALLOWED_ON_NON_LEAF</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_RDN">NOT_ALLOWED_ON_RDN</a></li>
+     * <li><a href="#ENTRY_ALREADY_EXISTS">ENTRY_ALREADY_EXISTS</a></li>
+     * <li><a href="#OBJECT_CLASS_MODS_PROHIBITED">OBJECT_CLASS_MODS_PROHIBITED</a></li>
+     * <li><a href="#AFFECTS_MULTIPLE_DSAS">AFFECTS_MULTIPLE_DSAS</a></li>
      * <li><a href="#OTHER">OTHER</a></li>
      * </ul>
      */
-    public static final Set EXTENDED_CODES;
+    public static final Set<ResultCodeEnum> EXTENDED_CODES;
     static
     {
-        HashSet set = new HashSet();
-        set.add( SUCCESS );
-        set.add( OPERATIONSERROR );
-        set.add( PROTOCOLERROR );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( SIZELIMITEXCEEDED );
-        set.add( COMPAREFALSE );
-        set.add( COMPARETRUE );
-        set.add( AUTHMETHODNOTSUPPORTED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( REFERRAL );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( UNAVAILABLECRITICALEXTENSION );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( SASLBINDINPROGRESS );
-        set.add( NOSUCHATTRIBUTE );
-        set.add( UNDEFINEDATTRIBUTETYPE );
-        set.add( INAPPROPRIATEMATCHING );
-        set.add( CONSTRAINTVIOLATION );
-        set.add( ATTRIBUTEORVALUEEXISTS );
-        set.add( INVALIDATTRIBUTESYNTAX );
-        set.add( NOSUCHOBJECT );
-        set.add( ALIASPROBLEM );
-        set.add( INVALIDDNSYNTAX );
-        set.add( ALIASDEREFERENCINGPROBLEM );
-        set.add( INAPPROPRIATEAUTHENTICATION );
-        set.add( INVALIDCREDENTIALS );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( BUSY );
-        set.add( UNAVAILABLE );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( LOOPDETECT );
-        set.add( NAMINGVIOLATION );
-        set.add( OBJECTCLASSVIOLATION );
-        set.add( NOTALLOWEDONNONLEAF );
-        set.add( NOTALLOWEDONRDN );
-        set.add( ENTRYALREADYEXISTS );
-        set.add( OBJECTCLASSMODSPROHIBITED );
-        set.add( AFFECTSMULTIPLEDSAS );
-        set.add( OTHER );
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.OPERATIONS_ERROR );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.SIZE_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.COMPARE_FALSE );
+        set.add( ResultCodeEnum.COMPARE_TRUE );
+        set.add( ResultCodeEnum.AUTH_METHOD_NOT_SUPPORTED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.SASL_BIND_IN_PROGRESS );
+        set.add( ResultCodeEnum.NO_SUCH_ATTRIBUTE );
+        set.add( ResultCodeEnum.UNDEFINED_ATTRIBUTE_TYPE );
+        set.add( ResultCodeEnum.INAPPROPRIATE_MATCHING );
+        set.add( ResultCodeEnum.CONSTRAINT_VIOLATION );
+        set.add( ResultCodeEnum.ATTRIBUTE_OR_VALUE_EXISTS );
+        set.add( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX );
+        set.add( ResultCodeEnum.NO_SUCH_OBJECT );
+        set.add( ResultCodeEnum.ALIAS_PROBLEM );
+        set.add( ResultCodeEnum.INVALID_DN_SYNTAX );
+        set.add( ResultCodeEnum.ALIAS_DEREFERENCING_PROBLEM );
+        set.add( ResultCodeEnum.INAPPROPRIATE_AUTHENTICATION );
+        set.add( ResultCodeEnum.INVALID_CREDENTIALS );
+        set.add( ResultCodeEnum.INSUFFICIENT_ACCESS_RIGHTS );
+        set.add( ResultCodeEnum.BUSY );
+        set.add( ResultCodeEnum.UNAVAILABLE );
+        set.add( ResultCodeEnum.UNWILLING_TO_PERFORM );
+        set.add( ResultCodeEnum.LOOP_DETECT );
+        set.add( ResultCodeEnum.NAMING_VIOLATION );
+        set.add( ResultCodeEnum.OBJECT_CLASS_VIOLATION );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_NON_LEAF );
+        set.add( ResultCodeEnum.NOT_ALLOWED_ON_RDN );
+        set.add( ResultCodeEnum.ENTRY_ALREADY_EXISTS );
+        set.add( ResultCodeEnum.OBJECT_CLASS_MODS_PROHIBITED );
+        set.add( ResultCodeEnum.AFFECTS_MULTIPLE_DSAS );
+        set.add( ResultCodeEnum.OTHER );
         EXTENDED_CODES = Collections.unmodifiableSet( set );
     }
 
@@ -1456,90 +1375,90 @@
      * <ul>
      * <li><a href="#SUCCESS">SUCCESS</a></li>
      * <li><a href="#OPERATIONSERROR">OPERATIONSERROR</a></li>
-     * <li><a href="#PROTOCOLERROR">PROTOCOLERROR</a></li>
-     * <li><a href="#TIMELIMITEXCEEDED">TIMELIMITEXCEEDED</a></li>
-     * <li><a href="#SIZELIMITEXCEEDED">SIZELIMITEXCEEDED</a></li>
+     * <li><a href="#PROTOCOL_ERROR">PROTOCOL_ERROR</a></li>
+     * <li><a href="#TIME_LIMIT_EXCEEDED">TIME_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#SIZE_LIMIT_EXCEEDED">SIZE_LIMIT_EXCEEDED</a></li>
      * <li><a href="#COMPAREFALSE">COMPAREFALSE</a></li>
      * <li><a href="#COMPARETRUE">COMPARETRUE</a></li>
-     * <li><a href="#AUTHMETHODNOTSUPPORTED">AUTHMETHODNOTSUPPORTED</a></li>
-     * <li><a href="#STRONGAUTHREQUIRED">STRONGAUTHREQUIRED</a></li>
-     * <li><a href="#PARTIALRESULTS">PARTIALRESULTS</a></li>
+     * <li><a href="#AUTH_METHOD_NOT_SUPPORTED">AUTH_METHOD_NOT_SUPPORTED</a></li>
+     * <li><a href="#STRONG_AUTH_REQUIRED">STRONG_AUTH_REQUIRED</a></li>
+     * <li><a href="#PARTIAL_RESULTS">PARTIAL_RESULTS</a></li>
      * <li><a href="#REFERRAL">REFERRAL</a></li>
-     * <li><a href="#ADMINLIMITEXCEEDED">ADMINLIMITEXCEEDED</a></li>
-     * <li><a href="#UNAVAILABLECRITICALEXTENSION">UNAVAILABLECRITICALEXTENSION</a></li>
-     * <li><a href="#CONFIDENTIALITYREQUIRED">CONFIDENTIALITYREQUIRED</a></li>
-     * <li><a href="#SASLBINDINPROGRESS">SASLBINDINPROGRESS</a></li>
-     * <li><a href="#NOSUCHATTRIBUTE">NOSUCHATTRIBUTE</a></li>
-     * <li><a href="#UNDEFINEDATTRIBUTETYPE">UNDEFINEDATTRIBUTETYPE</a></li>
-     * <li><a href="#INAPPROPRIATEMATCHING">INAPPROPRIATEMATCHING</a></li>
-     * <li><a href="#CONSTRAINTVIOLATION">CONSTRAINTVIOLATION</a></li>
-     * <li><a href="#ATTRIBUTEORVALUEEXISTS">ATTRIBUTEORVALUEEXISTS</a></li>
-     * <li><a href="#INVALIDATTRIBUTESYNTAX">INVALIDATTRIBUTESYNTAX</a></li>
-     * <li><a href="#NOSUCHOBJECT">NOSUCHOBJECT</a></li>
-     * <li><a href="#ALIASPROBLEM">ALIASPROBLEM</a></li>
-     * <li><a href="#INVALIDDNSYNTAX">INVALIDDNSYNTAX</a></li>
-     * <li><a href="#ALIASDEREFERENCINGPROBLEM">ALIASDEREFERENCINGPROBLEM</a></li>
-     * <li><a href="#INAPPROPRIATEAUTHENTICATION">INAPPROPRIATEAUTHENTICATION</a></li>
-     * <li><a href="#INVALIDCREDENTIALS">INVALIDCREDENTIALS</a></li>
-     * <li><a href="#INSUFFICIENTACCESSRIGHTS">INSUFFICIENTACCESSRIGHTS</a></li>
+     * <li><a href="#ADMIN_LIMIT_EXCEEDED">ADMIN_LIMIT_EXCEEDED</a></li>
+     * <li><a href="#UNAVAILABLE_CRITICAL_EXTENSION">UNAVAILABLE_CRITICAL_EXTENSION</a></li>
+     * <li><a href="#CONFIDENTIALITY_REQUIRED">CONFIDENTIALITY_REQUIRED</a></li>
+     * <li><a href="#SASL_BIND_IN_PROGRESS">SASL_BIND_IN_PROGRESS</a></li>
+     * <li><a href="#NO_SUCH_ATTRIBUTE">NO_SUCH_ATTRIBUTE</a></li>
+     * <li><a href="#UNDEFINED_ATTRIBUTE_TYPE">UNDEFINED_ATTRIBUTE_TYPE</a></li>
+     * <li><a href="#INAPPROPRIATE_MATCHING">INAPPROPRIATE_MATCHING</a></li>
+     * <li><a href="#CONSTRAINT_VIOLATION">CONSTRAINT_VIOLATION</a></li>
+     * <li><a href="#ATTRIBUTE_OR_VALUE_EXISTS">ATTRIBUTE_OR_VALUE_EXISTS</a></li>
+     * <li><a href="#INVALID_ATTRIBUTE_SYNTAX">INVALID_ATTRIBUTE_SYNTAX</a></li>
+     * <li><a href="#NO_SUCH_OBJECT">NO_SUCH_OBJECT</a></li>
+     * <li><a href="#ALIAS_PROBLEM">ALIAS_PROBLEM</a></li>
+     * <li><a href="#INVALID_DN_SYNTAX">INVALID_DN_SYNTAX</a></li>
+     * <li><a href="#ALIAS_DEREFERENCING_PROBLEM">ALIAS_DEREFERENCING_PROBLEM</a></li>
+     * <li><a href="#INAPPROPRIATE_AUTHENTICATION">INAPPROPRIATE_AUTHENTICATION</a></li>
+     * <li><a href="#INVALID_CREDENTIALS">INVALID_CREDENTIALS</a></li>
+     * <li><a href="#INSUFFICIENT_ACCESS_RIGHTS">INSUFFICIENT_ACCESS_RIGHTS</a></li>
      * <li><a href="#BUSY">BUSY</a></li>
      * <li><a href="#UNAVAILABLE">UNAVAILABLE</a></li>
-     * <li><a href="#UNWILLINGTOPERFORM">UNWILLINGTOPERFORM</a></li>
-     * <li><a href="#LOOPDETECT">LOOPDETECT</a></li>
-     * <li><a href="#NAMINGVIOLATION">NAMINGVIOLATION</a></li>
-     * <li><a href="#OBJECTCLASSVIOLATION">OBJECTCLASSVIOLATION</a></li>
-     * <li><a href="#NOTALLOWEDONNONLEAF">NOTALLOWEDONNONLEAF</a></li>
-     * <li><a href="#NOTALLOWEDONRDN">NOTALLOWEDONRDN</a></li>
-     * <li><a href="#ENTRYALREADYEXISTS">ENTRYALREADYEXISTS</a></li>
-     * <li><a href="#OBJECTCLASSMODSPROHIBITED">OBJECTCLASSMODSPROHIBITED</a></li>
-     * <li><a href="#AFFECTSMULTIPLEDSAS">AFFECTSMULTIPLEDSAS</a></li>
+     * <li><a href="#UNWILLING_TO_PERFORM">UNWILLING_TO_PERFORM</a></li>
+     * <li><a href="#LOOP_DETECT">LOOP_DETECT</a></li>
+     * <li><a href="#NAMING_VIOLATION">NAMING_VIOLATION</a></li>
+     * <li><a href="#OBJECT_CLASS_VIOLATION">OBJECT_CLASS_VIOLATION</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_NON_LEAF">NOT_ALLOWED_ON_NON_LEAF</a></li>
+     * <li><a href="#NOT_ALLOWED_ON_RDN">NOT_ALLOWED_ON_RDN</a></li>
+     * <li><a href="#ENTRY_ALREADY_EXISTS">ENTRY_ALREADY_EXISTS</a></li>
+     * <li><a href="#OBJECT_CLASS_MODS_PROHIBITED">OBJECT_CLASS_MODS_PROHIBITED</a></li>
+     * <li><a href="#AFFECTS_MULTIPLE_DSAS">AFFECTS_MULTIPLE_DSAS</a></li>
      * <li><a href="#OTHER">OTHER</a></li>
      * </ul>
      */
-    public static final Set ALL_CODES;
+    public static final Set<ResultCodeEnum> ALL_CODES;
     static
     {
-        HashSet set = new HashSet();
-        set.add( SUCCESS );
-        set.add( OPERATIONSERROR );
-        set.add( PROTOCOLERROR );
-        set.add( TIMELIMITEXCEEDED );
-        set.add( SIZELIMITEXCEEDED );
-        set.add( COMPAREFALSE );
-        set.add( COMPARETRUE );
-        set.add( AUTHMETHODNOTSUPPORTED );
-        set.add( STRONGAUTHREQUIRED );
-        set.add( PARTIALRESULTS );
-        set.add( REFERRAL );
-        set.add( ADMINLIMITEXCEEDED );
-        set.add( UNAVAILABLECRITICALEXTENSION );
-        set.add( CONFIDENTIALITYREQUIRED );
-        set.add( SASLBINDINPROGRESS );
-        set.add( NOSUCHATTRIBUTE );
-        set.add( UNDEFINEDATTRIBUTETYPE );
-        set.add( INAPPROPRIATEMATCHING );
-        set.add( CONSTRAINTVIOLATION );
-        set.add( ATTRIBUTEORVALUEEXISTS );
-        set.add( INVALIDATTRIBUTESYNTAX );
-        set.add( NOSUCHOBJECT );
-        set.add( ALIASPROBLEM );
-        set.add( INVALIDDNSYNTAX );
-        set.add( ALIASDEREFERENCINGPROBLEM );
-        set.add( INAPPROPRIATEAUTHENTICATION );
-        set.add( INVALIDCREDENTIALS );
-        set.add( INSUFFICIENTACCESSRIGHTS );
-        set.add( BUSY );
-        set.add( UNAVAILABLE );
-        set.add( UNWILLINGTOPERFORM );
-        set.add( LOOPDETECT );
-        set.add( NAMINGVIOLATION );
-        set.add( OBJECTCLASSVIOLATION );
-        set.add( NOTALLOWEDONNONLEAF );
-        set.add( NOTALLOWEDONRDN );
-        set.add( ENTRYALREADYEXISTS );
-        set.add( OBJECTCLASSMODSPROHIBITED );
-        set.add( AFFECTSMULTIPLEDSAS );
-        set.add( OTHER );
+        Set<ResultCodeEnum> set = new HashSet<ResultCodeEnum>();
+        set.add( ResultCodeEnum.SUCCESS );
+        set.add( ResultCodeEnum.OPERATIONS_ERROR );
+        set.add( ResultCodeEnum.PROTOCOL_ERROR );
+        set.add( ResultCodeEnum.TIME_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.SIZE_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.COMPARE_FALSE );
+        set.add( ResultCodeEnum.COMPARE_TRUE );
+        set.add( ResultCodeEnum.AUTH_METHOD_NOT_SUPPORTED );
+        set.add( ResultCodeEnum.STRONG_AUTH_REQUIRED );
+        set.add( ResultCodeEnum.PARTIAL_RESULTS );
+        set.add( ResultCodeEnum.REFERRAL );
+        set.add( ResultCodeEnum.ADMIN_LIMIT_EXCEEDED );
+        set.add( ResultCodeEnum.UNAVAILABLE_CRITICAL_EXTENSION );
+        set.add( ResultCodeEnum.CONFIDENTIALITY_REQUIRED );
+        set.add( ResultCodeEnum.SASL_BIND_IN_PROGRESS );
+        set.add( ResultCodeEnum.NO_SUCH_ATTRIBUTE );
+        set.add( ResultCodeEnum.UNDEFINED_ATTRIBUTE_TYPE );
+        set.add( ResultCodeEnum.INAPPROPRIATE_MATCHING );

[... 877 lines stripped ...]


Mime
View raw message