directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r923840 - in /directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema: AttributeType.java ObjectClass.java
Date Tue, 16 Mar 2010 16:24:52 GMT
Author: elecharny
Date: Tue Mar 16 16:24:52 2010
New Revision: 923840

URL: http://svn.apache.org/viewvc?rev=923840&view=rev
Log:
Thow a ProtocolError instead of a SchemaViolationException

Modified:
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/AttributeType.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/ObjectClass.java

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/AttributeType.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/AttributeType.java?rev=923840&r1=923839&r2=923840&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/AttributeType.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/AttributeType.java
Tue Mar 16 16:24:52 2010
@@ -26,6 +26,7 @@ import java.util.Set;
 
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.exception.LdapException;
+import org.apache.directory.shared.ldap.exception.LdapProtocolErrorException;
 import org.apache.directory.shared.ldap.exception.LdapSchemaViolationException;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.schema.registries.AttributeTypeRegistry;
@@ -225,7 +226,7 @@ public class AttributeType extends Abstr
                 // Not allowed.
                 String msg = I18n.err( I18n.ERR_04303, superiorOid, getName() );
 
-                Throwable error = new LdapSchemaViolationException( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX,
msg );
+                Throwable error = new LdapProtocolErrorException( msg );
                 errors.add( error );
                 LOG.info( msg );
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/ObjectClass.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/ObjectClass.java?rev=923840&r1=923839&r2=923840&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/ObjectClass.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/ObjectClass.java
Tue Mar 16 16:24:52 2010
@@ -25,6 +25,7 @@ import java.util.List;
 
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.exception.LdapException;
+import org.apache.directory.shared.ldap.exception.LdapProtocolErrorException;
 import org.apache.directory.shared.ldap.exception.LdapSchemaViolationException;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.schema.registries.AttributeTypeRegistry;
@@ -189,7 +190,7 @@ public class ObjectClass extends Abstrac
                     // Cannot find the OC
                     String msg = I18n.err( I18n.ERR_04321, oid, superiorName );
 
-                    Throwable error = new LdapSchemaViolationException( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX,
msg );
+                    Throwable error = new LdapProtocolErrorException( msg );
                     errors.add( error );
                     return;
                 }



Mime
View raw message