directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r936707 - in /directory: apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/ shared/trunk/i18n/src/main/java/org/apache/directory/shared/i18n/ shared/trunk/i18n/src/main/resources/org/apache/directory/shared/i18n...
Date Thu, 22 Apr 2010 09:55:00 GMT
Author: elecharny
Date: Thu Apr 22 09:55:00 2010
New Revision: 936707

URL: http://svn.apache.org/viewvc?rev=936707&view=rev
Log:
o Fixed some error message (double quote)
o Modified the ERR_04442 message code

Added:
    directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java
      - copied, changed from r936627, directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java
Modified:
    directory/shared/trunk/i18n/src/main/java/org/apache/directory/shared/i18n/I18n.java
    directory/shared/trunk/i18n/src/main/resources/org/apache/directory/shared/i18n/errors.properties
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/BinaryValue.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntryAttribute.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/StringValue.java

Copied: directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java
(from r936627, directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java)
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java?p2=directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java&p1=directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java&r1=936627&r2=936707&rev=936707&view=diff
==============================================================================
--- directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java
(original)
+++ directory/apacheds/trunk/core-entry/src/test/java/org/apache/directory/server/core/entry/DefaultEntryAttributeTest.java
Thu Apr 22 09:55:00 2010
@@ -42,6 +42,7 @@ import java.util.Set;
 import javax.naming.directory.InvalidAttributeValueException;
 
 import org.apache.commons.io.FileUtils;
+import org.apache.directory.server.core.entry.TestServerEntryUtils;
 import org.apache.directory.shared.ldap.entry.BinaryValue;
 import org.apache.directory.shared.ldap.entry.DefaultEntryAttribute;
 import org.apache.directory.shared.ldap.entry.StringValue;

Modified: directory/shared/trunk/i18n/src/main/java/org/apache/directory/shared/i18n/I18n.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/i18n/src/main/java/org/apache/directory/shared/i18n/I18n.java?rev=936707&r1=936706&r2=936707&view=diff
==============================================================================
--- directory/shared/trunk/i18n/src/main/java/org/apache/directory/shared/i18n/I18n.java (original)
+++ directory/shared/trunk/i18n/src/main/java/org/apache/directory/shared/i18n/I18n.java Thu
Apr 22 09:55:00 2010
@@ -584,7 +584,7 @@ public class I18n
 	public static final String ERR_04439 = "ERR_04439";
 	public static final String ERR_04440 = "ERR_04440";
     public static final String ERR_04441 = "ERR_04441";
-    public static final String ERR_04442 = "ERR_04442";
+    public static final String ERR_04442_NULL_AT_NOT_ALLOWED = "ERR_04442_NULL_AT_NOT_ALLOWED";
     public static final String ERR_04443 = "ERR_04443";
     public static final String ERR_04444 = "ERR_04444";
     public static final String ERR_04445 = "ERR_04445";

Modified: directory/shared/trunk/i18n/src/main/resources/org/apache/directory/shared/i18n/errors.properties
URL: http://svn.apache.org/viewvc/directory/shared/trunk/i18n/src/main/resources/org/apache/directory/shared/i18n/errors.properties?rev=936707&r1=936706&r2=936707&view=diff
==============================================================================
--- directory/shared/trunk/i18n/src/main/resources/org/apache/directory/shared/i18n/errors.properties
(original)
+++ directory/shared/trunk/i18n/src/main/resources/org/apache/directory/shared/i18n/errors.properties
Thu Apr 22 09:55:00 2010
@@ -12,7 +12,7 @@ ERR_00010=Truncated PDU. Some elements a
 ERR_00011=Length above 126 bytes are not allowed for a definite form Length
 ERR_00012=argument not a byte array
 ERR_00013=Odd number of characters.
-ERR_00014=Illegal hexadecimal charcter {0} at index {1}
+ERR_00014=Illegal hexadecimal character {0} at index {1}
 ERR_00015=non-hex character ''{0}'' encountered
 ERR_00016=End of stream.
 ERR_00017=EOF found when length expected.
@@ -70,7 +70,7 @@ ERR_03007=Incorrect value for 'criticali
 ERR_03008=An unexpected error ocurred : {0}
 ERR_03009=the given resultCode is not an integer
 ERR_03010=code attribute is required
-ERR_03011=descr ('{0}') doesn't match with the possible values
+ERR_03011=descr (''{0}'') doesn't match with the possible values
 ERR_03012=name attribute is required
 ERR_03013=Unknown value for 'processing' attribute.
 ERR_03014=Unknown value for 'onError' attribute.
@@ -132,13 +132,13 @@ ERR_04027=Bad UUID value, its length is 
 ERR_04028=failed to decode the mode for SyncRequestValueControl
 ERR_04029=failed to decode the reloadHint flag for SyncRequestValueControl
 ERR_04030=failed to decode the mode for SyncStateValueControl
-ERR_04031=failed to decode the cancelId, the value should be between 0 and 2^31-1, it is
''{0}'
+ERR_04031=failed to decode the cancelId, the value should be between 0 and 2^31-1, it is
''{0}''
 ERR_04032=invalid target DN {0}
-ERR_04033=failed to decode the target DN, it cannot be null or empty it is ''{0}'
+ERR_04033=failed to decode the target DN, it cannot be null or empty it is ''{0}''
 ERR_04034=invalid issuer DN {0}
 ERR_04035=invalid subject DN {0}
-ERR_04036=failed to decode the delay, the value should be between 0 and 86400 seconds, it
is ''{0}'
-ERR_04037=failed to decode the timeOffline, the value should be between 0 and 720 minutes,
it is ''{0}'
+ERR_04036=failed to decode the delay, the value should be between 0 and 86400 seconds, it
is ''{0}''
+ERR_04037=failed to decode the timeOffline, the value should be between 0 and 720 minutes,
it is ''{0}''
 ERR_04038=The stored procedure language is null
 ERR_04039=The procedure can't be null
 ERR_04040=The parameter type can't be null
@@ -148,7 +148,7 @@ ERR_04043=The request name must not be n
 ERR_04044=failed to decode the changeType for EntryChangeControl
 ERR_04045=The previousDN field should not contain anything if the changeType is not MODDN
 ERR_04046=Previous DN is not allowed for this change type
-ERR_04047=Bad Previous DN : ''{0}'
+ERR_04047=Bad Previous DN : ''{0}''
 ERR_04048=failed to decode the previous DN
 ERR_04049=failed to decode the changeNumber for EntryChangeControl
 ERR_04050=failed to decode the size for PagedSearchControl
@@ -217,13 +217,13 @@ ERR_04112=Error while transforming a Exp
 ERR_04113=shouldn't happen - if it does then we have issues
 ERR_04114=The CSN must not be null or empty
 ERR_04115=The CSN's length is incorrect, it should be 40 chars long
-ERR_04116=Cannot find a '#' in the CSN ''{0}'
+ERR_04116=Cannot find a '#' in the CSN ''{0}''
 ERR_04117=The timestamp is not long enough
-ERR_04118=Cannot parse the timestamp: ''{0}'
+ERR_04118=Cannot parse the timestamp: ''{0}''
 ERR_04119=The microseconds part is invalid
-ERR_04120=Missing a '#' in the CSN ''{0}'
+ERR_04120=Missing a '#' in the CSN ''{0}''
 ERR_04121=The changeCount ''{0}'' is not a valid number
-ERR_04122=Missing a '#' in the CSN ''{0}'
+ERR_04122=Missing a '#' in the CSN ''{0}''
 ERR_04123=The replicaID must not be null or empty
 ERR_04124=The replicaId ''{0}'' is not a valid number
 ERR_04125=The operationNumber is absent
@@ -235,7 +235,7 @@ ERR_04130=The value is expected to be a 
 ERR_04131=The value is expected to be a String
 ERR_04132=An ID cannnot be null, empty, or resolved to an emtpy value when trimmed
 ERR_04133=The attributeType ID should not be null or empty
-ERR_04134=An exception has been raised while looking for attribute id ''{0}'
+ERR_04134=An exception has been raised while looking for attribute id ''{0}''
 ERR_04135=The AttributeType list should not be null
 ERR_04136=The AttributeType list should not contain null values
 ERR_04137=The attribute ''{0}'' does not exist in the entry
@@ -388,11 +388,11 @@ ERR_04283=Cannot modify the NormalizerRe
 ERR_04284=Cannot modify the ObjectClassRegistry copy
 ERR_04285=Cannot modify the SyntaxCheckerRegistry copy
 ERR_04286=OID ''{0}'' was not found within the OID registry
-ERR_04287=There is no SchemaObject associated with OID ''{0}'
+ERR_04287=There is no SchemaObject associated with OID ''{0}''
 ERR_04288=OID ''{0}'' was not found within the OID registry
 ERR_04289=Cannot register a Null SchemaObject !
 ERR_04290=The given SchemaObject does not have a valid OID
-ERR_04291=There is already a SchemaObject for OID ''{0}'
+ERR_04291=There is already a SchemaObject for OID ''{0}''
 ERR_04292=Cannot build the references for {0}, error : {1}
 ERR_04293=Cannot remove the references for {0}, error : {1}
 ERR_04294=The MatchingRule {0} does not have a syntax. This is invalid
@@ -428,7 +428,7 @@ ERR_04323=Cannot register the SchemaOjec
 ERR_04324=Cannot register the SchemaOject {0}, there are some duplicate AT in the MUST :
{1}
 ERR_04325=Cannot register the SchemaOject {0}, there are some duplicate AT in MAY and MUST
: {1}
 ERR_04326=Cannot register the SchemaOject {0}, the AT we want to add to MUST does not exist
: {1}
-ERR_04327=Unknown objectClass type name ''{0}': options are AUXILIARY, STRUCTURAL, ABSTRACT.
+ERR_04327=Unknown objectClass type name ''{0}'': options are AUXILIARY, STRUCTURAL, ABSTRACT.
 ERR_04328=undefined modification type: {0}
 ERR_04329=Parser failure on subtree specification\:\n\t{0}\nAntlr exception trace\:\n{1}
 ERR_04330=A negative minimum base distance is undefined!
@@ -501,9 +501,9 @@ ERR_04396=Value alteration is not suppor
 ERR_04397=Iterator[] arg must not be null, empty or composed of less than two Iterators
 ERR_04398=A LdapUrl must start with "ldap\://" or "ldaps\://"
 ERR_04399=The hostport is invalid
-ERR_04400=Bad character, position {0}, ''{1}', '/' expected"
+ERR_04400=Bad character, position {0}, ''{1}'', '/' expected"
 ERR_04401=The DN is invalid
-ERR_04402=Bad character, position {0}, ''{1}', '?' expected
+ERR_04402=Bad character, position {0}, ''{1}'', '?' expected
 ERR_04403=Attributes are invalid
 ERR_04404=Scope is invalid
 ERR_04405=Filter is invalid
@@ -538,12 +538,12 @@ ERR_04433=Expected string to be non-null
 ERR_04434=Expected string to be non-empty with valid index.
 ERR_04435=The DN must contain valid escaped characters.
 ERR_04436=The DN must not ends with a '\\'.
-ERR_04437=Caught a SecurityException reading the system property ''{0}'; the SystemUtils
property value will default to null.
+ERR_04437=Caught a SecurityException reading the system property ''{0}''; the SystemUtils
property value will default to null.
 ERR_04438=The style must not be null
 ERR_04439=Usage - java org.mortbay.util.UnixCrypt <key> <salt>
 ERR_04440=Crypt={0}
 ERR_04441=Cannot modify the SchemaObject {0}, it has been locked
-ERR_04442=The AttributeType parameter should not be null
+ERR_04442_NULL_AT_NOT_ALLOWED=The AttributeType parameter should not be null
 ERR_04443=Failed to compare normalized values for {0} and {1}
 ERR_04444=I don't really know how to compare anything other than ServerBinaryValues at this
point in time.
 ERR_04445=There is no Syntax associated with this attributeType
@@ -556,7 +556,7 @@ ERR_04451=The value must be a String, as
 ERR_04452=The value must be a byte[], as its AttributeType is not H/R
 ERR_04453=The upID ({0}) is not an OID or is different from the AttributeType OID ({1})
 ERR_04454=Cannot use standard serialization for a ServerAttribute
-ERR_04455=The ID ''{0}'is incompatible with the AttributeType's id ''{1}'
+ERR_04455=The ID ''{0}''is incompatible with the AttributeType's id ''{1}''
 ERR_04456=An ID cannnot be null, empty, or resolved to an emtpy value when trimmed
 ERR_04457=The ID should not be null or empty
 ERR_04458=Cannot add an attribute without an ID
@@ -571,7 +571,7 @@ ERR_04466=The removal of values for the 
 ERR_04467=The AttributeType list should not contain null values
 ERR_04468=Cannot use standard serialization for a ServerAttribute
 ERR_04469=Cannot use standard serialization for a ServerEntry
-ERR_04470=Cannot read the attribute as it's OID ('{0}') does not exist
+ERR_04470=Cannot read the attribute as it's OID (''{0}'') does not exist
 ERR_04471=Cannot serialize a Modification with no attribute
 ERR_04472=The attribute ''{0}'' is incorrect
 ERR_04473=Not a valid value

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/BinaryValue.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/BinaryValue.java?rev=936707&r1=936706&r2=936707&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/BinaryValue.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/BinaryValue.java
Thu Apr 22 09:55:00 2010
@@ -78,7 +78,9 @@ public class BinaryValue extends Abstrac
     {
         if ( attributeType == null )
         {
-            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442 ) );
+            String message = I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED );
+            LOG.error( message );
+            throw new IllegalArgumentException( message );
         }
 
         if ( attributeType.getSyntax() == null )

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntryAttribute.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntryAttribute.java?rev=936707&r1=936706&r2=936707&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntryAttribute.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntryAttribute.java
Thu Apr 22 09:55:00 2010
@@ -166,7 +166,9 @@ public class DefaultEntryAttribute imple
     {
         if ( attributeType == null )
         {
-            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442 ) );
+            String message = I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED );
+            LOG.error( message );
+            throw new IllegalArgumentException( message );
         }
         
         setAttributeType( attributeType );
@@ -192,7 +194,7 @@ public class DefaultEntryAttribute imple
     {
         if ( attributeType == null ) 
         {
-            String message = I18n.err( I18n.ERR_04442 );
+            String message = I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED );
             LOG.error( message );
             throw new IllegalArgumentException( message );
         }
@@ -264,7 +266,9 @@ public class DefaultEntryAttribute imple
     {
         if ( attributeType == null )
         {
-            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442 ) );
+            String message = I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED );
+            LOG.error( message );
+            throw new IllegalArgumentException( message );
         }
 
         setAttributeType( attributeType );
@@ -290,7 +294,9 @@ public class DefaultEntryAttribute imple
     {
         if ( attributeType == null )
         {
-            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442 ) );
+            String message = I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED );
+            LOG.error( message );
+            throw new IllegalArgumentException( message );
         }
         
         setAttributeType( attributeType );
@@ -358,7 +364,7 @@ public class DefaultEntryAttribute imple
     {
         if ( attributeType == null )
         {
-            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442 ) );
+            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED
) );
         }
 
         setAttributeType( attributeType );

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/StringValue.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/StringValue.java?rev=936707&r1=936706&r2=936707&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/StringValue.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/StringValue.java
Thu Apr 22 09:55:00 2010
@@ -76,7 +76,9 @@ public class StringValue extends Abstrac
     {
         if ( attributeType == null )
         {
-            throw new IllegalArgumentException( I18n.err( I18n.ERR_04442 ) );
+            String message = I18n.err( I18n.ERR_04442_NULL_AT_NOT_ALLOWED );
+            LOG.error( message );
+            throw new IllegalArgumentException( message );
         }
 
         if ( attributeType.getSyntax() == null )



Mime
View raw message