directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r1062251 [5/13] - in /directory: apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/ apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/entry/ apacheds/trunk/core-api/src/main/java/org/apache/director...
Date Sat, 22 Jan 2011 20:08:59 GMT
Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapMessageGrammar.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapMessageGrammar.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapMessageGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapMessageGrammar.java Sat Jan 22 20:08:48 2011
@@ -121,6 +121,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.name.DN;
 import org.apache.directory.shared.ldap.name.RDN;
 import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -360,7 +361,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -581,7 +582,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -637,7 +638,7 @@ public final class LdapMessageGrammar ex
                     // We have to handle the special case of a 0 length simple
                     if ( tlv.getLength() == 0 )
                     {
-                        bindRequestMessage.setCredentials( StringTools.EMPTY_BYTES );
+                        bindRequestMessage.setCredentials( StringConstants.EMPTY_BYTES );
                     }
                     else
                     {
@@ -736,7 +737,7 @@ public final class LdapMessageGrammar ex
                     }
                     else
                     {
-                        bindRequestMessage.setSaslMechanism( StringTools.utf8ToString( tlv.getValue().getData() ) );
+                        bindRequestMessage.setSaslMechanism( Strings.utf8ToString(tlv.getValue().getData()) );
                     }
 
                     // We can have an END transition
@@ -774,7 +775,7 @@ public final class LdapMessageGrammar ex
                     // credentials
                     if ( tlv.getLength() == 0 )
                     {
-                        bindRequestMessage.setCredentials( StringTools.EMPTY_BYTES );
+                        bindRequestMessage.setCredentials( StringConstants.EMPTY_BYTES );
                     }
                     else
                     {
@@ -1130,7 +1131,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -1445,7 +1446,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -1875,7 +1876,7 @@ public final class LdapMessageGrammar ex
                     {
                         DN entryDn = null;
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -2177,7 +2178,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -2244,7 +2245,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -2372,7 +2373,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -2524,7 +2525,7 @@ public final class LdapMessageGrammar ex
                     else
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -2655,7 +2656,7 @@ public final class LdapMessageGrammar ex
                         }
                         else
                         {
-                            compareRequest.setAssertionValue( StringTools.utf8ToString( tlv.getValue().getData() ) );
+                            compareRequest.setAssertionValue( Strings.utf8ToString(tlv.getValue().getData()) );
 
                             if ( LOG.isDebugEnabled() )
                             {
@@ -2850,13 +2851,13 @@ public final class LdapMessageGrammar ex
 
                         try
                         {
-                            String requestName = StringTools.utf8ToString( requestNameBytes );
+                            String requestName = Strings.utf8ToString(requestNameBytes);
 
                             if ( !OID.isOID( requestName ) )
                             {
 
                                 String msg = "The Request name is not a valid OID : "
-                                    + StringTools.utf8ToString( requestNameBytes ) + " ("
+                                    + Strings.utf8ToString(requestNameBytes) + " ("
                                     + Strings.dumpBytes(requestNameBytes) + ") is invalid";
                                 LOG.error( msg );
 
@@ -2869,7 +2870,7 @@ public final class LdapMessageGrammar ex
                         catch ( DecoderException de )
                         {
                             String msg = "The Request name is not a valid OID : "
-                                + StringTools.utf8ToString( requestNameBytes ) + " ("
+                                + Strings.utf8ToString(requestNameBytes) + " ("
                                 + Strings.dumpBytes(requestNameBytes) + ") is invalid";
                             LOG.error( "{} : {}", msg, de.getMessage() );
 
@@ -2914,7 +2915,7 @@ public final class LdapMessageGrammar ex
                     // value
                     if ( tlv.getLength() == 0 )
                     {
-                        extendedRequest.setRequestValue( StringTools.EMPTY_BYTES );
+                        extendedRequest.setRequestValue( StringConstants.EMPTY_BYTES );
                     }
                     else
                     {
@@ -3225,7 +3226,7 @@ public final class LdapMessageGrammar ex
                     {
                         byte[] responseNameBytes = tlv.getValue().getData();
 
-                        String oidStr = StringTools.utf8ToString( responseNameBytes );
+                        String oidStr = Strings.utf8ToString(responseNameBytes);
 
                         if ( OID.isOID( oidStr ) )
                         {
@@ -3235,7 +3236,7 @@ public final class LdapMessageGrammar ex
                         else
                         {
                             String msg = "The Intermediate Response name is not a valid OID : "
-                                + StringTools.utf8ToString( responseNameBytes ) + " ("
+                                + Strings.utf8ToString(responseNameBytes) + " ("
                                 + Strings.dumpBytes(responseNameBytes) + ") is invalid";
                             LOG.error( "{} : {}", msg, oidStr );
 
@@ -3281,7 +3282,7 @@ public final class LdapMessageGrammar ex
                     // value
                     if ( tlv.getLength() == 0 )
                     {
-                        intermediateResponse.setResponseValue( StringTools.EMPTY_BYTES );
+                        intermediateResponse.setResponseValue( StringConstants.EMPTY_BYTES );
                     }
                     else
                     {
@@ -3324,7 +3325,7 @@ public final class LdapMessageGrammar ex
                     // value
                     if ( tlv.getLength() == 0 )
                     {
-                        intermediateResponse.setResponseValue( StringTools.EMPTY_BYTES );
+                        intermediateResponse.setResponseValue( StringConstants.EMPTY_BYTES );
                     }
                     else
                     {
@@ -3429,7 +3430,7 @@ public final class LdapMessageGrammar ex
                     }
 
                     byte[] value = tlv.getValue().getData();
-                    String oidValue = StringTools.asciiBytesToString( value );
+                    String oidValue = Strings.asciiBytesToString(value);
 
                     // The OID is encoded as a String, not an Object Id
                     if ( !OID.isOID(oidValue) )
@@ -3625,7 +3626,7 @@ public final class LdapMessageGrammar ex
                     if ( tlv.getLength() != 0 )
                     {
                         byte[] dnBytes = tlv.getValue().getData();
-                        String dnStr = StringTools.utf8ToString( dnBytes );
+                        String dnStr = Strings.utf8ToString(dnBytes);
 
                         try
                         {
@@ -5123,7 +5124,7 @@ public final class LdapMessageGrammar ex
                         throw new DecoderException( msg );
                     }
 
-                    substringFilter.setInitialSubstrings( StringTools.utf8ToString( tlv.getValue().getData() ) );
+                    substringFilter.setInitialSubstrings( Strings.utf8ToString(tlv.getValue().getData()) );
 
                     // We now have to get back to the nearest filter which is
                     // not terminal.
@@ -6048,7 +6049,7 @@ public final class LdapMessageGrammar ex
                     }
                     else
                     {
-                        extensibleMatchFilter.setMatchingRule( StringTools.utf8ToString( tlv.getValue().getData() ) );
+                        extensibleMatchFilter.setMatchingRule( Strings.utf8ToString(tlv.getValue().getData()) );
                     }
                 }
             } );

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/AttributeDescAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/AttributeDescAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/AttributeDescAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/AttributeDescAction.java Sat Jan 22 20:08:48 2011
@@ -26,7 +26,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.DecoderException;
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.SearchRequest;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -68,10 +68,10 @@ public class AttributeDescAction extends
 
         if ( tlv.getLength() != 0 )
         {
-            attributeDescription = StringTools.utf8ToString( tlv.getValue().getData() );
+            attributeDescription = Strings.utf8ToString(tlv.getValue().getData());
 
             // If the attributeDescription is empty, we won't add it
-            if ( !StringTools.isEmpty( attributeDescription.trim() ) )
+            if ( !Strings.isEmpty(attributeDescription.trim()) )
             {
                 searchRequest.addAttributes( attributeDescription );
             }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ControlValueAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ControlValueAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ControlValueAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ControlValueAction.java Sat Jan 22 20:08:48 2011
@@ -30,7 +30,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.codec.controls.ControlDecoder;
 import org.apache.directory.shared.ldap.message.Message;
 import org.apache.directory.shared.ldap.message.control.Control;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -72,7 +72,7 @@ public class ControlValueAction extends 
         // Store the value - have to handle the special case of a 0 length value
         if ( tlv.getLength() == 0 )
         {
-            control.setValue( StringTools.EMPTY_BYTES );
+            control.setValue( StringConstants.EMPTY_BYTES );
         }
         else
         {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ErrorMessageAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ErrorMessageAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ErrorMessageAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ErrorMessageAction.java Sat Jan 22 20:08:48 2011
@@ -27,7 +27,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.LdapResult;
 import org.apache.directory.shared.ldap.message.ResultResponse;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -74,7 +74,7 @@ public class ErrorMessageAction extends 
         }
         else
         {
-            errorMessage = StringTools.utf8ToString( tlv.getValue().getData() );
+            errorMessage = Strings.utf8ToString(tlv.getValue().getData());
         }
 
         ResultResponse response = ( ResultResponse ) ldapMessageContainer.getMessage();

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAssertionValueFilterAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAssertionValueFilterAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAssertionValueFilterAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAssertionValueFilterAction.java Sat Jan 22 20:08:48 2011
@@ -32,7 +32,8 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.entry.Value;
 import org.apache.directory.shared.ldap.message.SearchRequest;
 import org.apache.directory.shared.ldap.message.SearchRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -79,7 +80,7 @@ public class InitAssertionValueFilterAct
         }
         else
         {
-            assertionValue = new BinaryValue( StringTools.EMPTY_BYTES );
+            assertionValue = new BinaryValue( StringConstants.EMPTY_BYTES );
         }
 
         AttributeValueAssertionFilter terminalFilter = ( AttributeValueAssertionFilter ) ( ( SearchRequestImpl ) searchRequest )
@@ -94,7 +95,7 @@ public class InitAssertionValueFilterAct
             }
             else
             {
-                assertionValue = new BinaryValue( StringTools.EMPTY_BYTES );
+                assertionValue = new BinaryValue( StringConstants.EMPTY_BYTES );
             }
 
             assertion.setAssertionValue( assertionValue );
@@ -103,7 +104,7 @@ public class InitAssertionValueFilterAct
         {
             if ( tlv.getLength() != 0 )
             {
-                assertionValue = new StringValue( StringTools.utf8ToString( tlv.getValue().getData() ) );
+                assertionValue = new StringValue( Strings.utf8ToString(tlv.getValue().getData()) );
             }
             else
             {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAttributeDescFilterAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAttributeDescFilterAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAttributeDescFilterAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitAttributeDescFilterAction.java Sat Jan 22 20:08:48 2011
@@ -30,7 +30,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.codec.search.AttributeValueAssertionFilter;
 import org.apache.directory.shared.ldap.message.SearchRequest;
 import org.apache.directory.shared.ldap.message.SearchRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -78,7 +78,7 @@ public class InitAttributeDescFilterActi
         }
         else
         {
-            String type = StringTools.utf8ToString( tlv.getValue().getData() );
+            String type = Strings.utf8ToString(tlv.getValue().getData());
             assertion.setAttributeDesc( type );
 
             AttributeValueAssertionFilter terminalFilter = ( AttributeValueAssertionFilter ) ( ( SearchRequestImpl ) searchRequest )

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitPresentFilterAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitPresentFilterAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitPresentFilterAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/InitPresentFilterAction.java Sat Jan 22 20:08:48 2011
@@ -28,7 +28,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.codec.search.PresentFilter;
 import org.apache.directory.shared.ldap.message.SearchRequest;
 import org.apache.directory.shared.ldap.message.SearchRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -73,16 +73,16 @@ public class InitPresentFilterAction ext
         ( ( SearchRequestImpl ) searchRequest ).addCurrentFilter( presentFilter );
         ( ( SearchRequestImpl ) searchRequest ).setTerminalFilter( presentFilter );
 
-        String value = StringTools.utf8ToString( tlv.getValue().getData() );
+        String value = Strings.utf8ToString(tlv.getValue().getData());
 
-        if ( StringTools.isEmpty( value ) )
+        if ( Strings.isEmpty(value) )
         {
             presentFilter.setAttributeDescription( "" );
         }
         else
         {
             // Store the value.
-            String type = StringTools.utf8ToString( tlv.getValue().getData() );
+            String type = Strings.utf8ToString(tlv.getValue().getData());
             presentFilter.setAttributeDescription( type );
         }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/MatchedDNAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/MatchedDNAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/MatchedDNAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/MatchedDNAction.java Sat Jan 22 20:08:48 2011
@@ -31,7 +31,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.message.ResultResponse;
 import org.apache.directory.shared.ldap.name.DN;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -95,7 +94,7 @@ public class MatchedDNAction extends Gra
                 case INVALID_DN_SYNTAX:
                 case ALIAS_DEREFERENCING_PROBLEM:
                     byte[] dnBytes = tlv.getValue().getData();
-                    String dnStr = StringTools.utf8ToString( dnBytes );
+                    String dnStr = Strings.utf8ToString(dnBytes);
 
                     try
                     {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ModifyAttributeValueAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ModifyAttributeValueAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ModifyAttributeValueAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ModifyAttributeValueAction.java Sat Jan 22 20:08:48 2011
@@ -26,7 +26,8 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.ModifyRequest;
 import org.apache.directory.shared.ldap.message.ModifyRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -65,7 +66,7 @@ public class ModifyAttributeValueAction 
         TLV tlv = ldapMessageContainer.getCurrentTLV();
 
         // Store the value. It can't be null
-        byte[] value = StringTools.EMPTY_BYTES;
+        byte[] value = StringConstants.EMPTY_BYTES;
 
         if ( tlv.getLength() == 0 )
         {
@@ -82,7 +83,7 @@ public class ModifyAttributeValueAction 
             else
             {
                 ( ( ModifyRequestImpl ) modifyRequest )
-                    .addAttributeValue( StringTools.utf8ToString( ( byte[] ) value ) );
+                    .addAttributeValue( Strings.utf8ToString((byte[]) value) );
             }
         }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ReferralAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ReferralAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ReferralAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ReferralAction.java Sat Jan 22 20:08:48 2011
@@ -33,7 +33,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.message.ResultResponse;
 import org.apache.directory.shared.ldap.util.LdapURL;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -88,7 +88,7 @@ public class ReferralAction extends Gram
                 }
                 catch ( LdapURLEncodingException luee )
                 {
-                    String badUrl = StringTools.utf8ToString( tlv.getValue().getData() );
+                    String badUrl = Strings.utf8ToString(tlv.getValue().getData());
                     LOG.error( I18n.err( I18n.ERR_04015, badUrl, luee.getMessage() ) );
                     throw new DecoderException( I18n.err( I18n.ERR_04016, luee.getMessage() ) );
                 }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseAction.java Sat Jan 22 20:08:48 2011
@@ -26,7 +26,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.TLV;
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.ExtendedResponse;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -72,7 +72,7 @@ public class ResponseAction extends Gram
         // OID
         if ( tlv.getLength() == 0 )
         {
-            extendedResponse.setResponseValue( StringTools.EMPTY_BYTES );
+            extendedResponse.setResponseValue( StringConstants.EMPTY_BYTES );
         }
         else
         {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseNameAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseNameAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseNameAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ResponseNameAction.java Sat Jan 22 20:08:48 2011
@@ -28,7 +28,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.ExtendedResponse;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -79,7 +79,7 @@ public class ResponseNameAction extends 
         }
         else
         {
-            extendedResponse.setResponseName( new OID( StringTools.asciiBytesToString( tlv.getValue().getData() ) )
+            extendedResponse.setResponseName( new OID( Strings.asciiBytesToString(tlv.getValue().getData()) )
                 .toString() );
         }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/SearchResultAttributeValueAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/SearchResultAttributeValueAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/SearchResultAttributeValueAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/SearchResultAttributeValueAction.java Sat Jan 22 20:08:48 2011
@@ -25,7 +25,6 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.TLV;
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.SearchResultEntry;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -86,7 +85,7 @@ public class SearchResultAttributeValueA
             }
             else
             {
-                value = StringTools.utf8ToString( tlv.getValue().getData() );
+                value = Strings.utf8ToString(tlv.getValue().getData());
 
                 LOG.debug( "Attribute value {}", value );
             }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ServerSASLCredsAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ServerSASLCredsAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ServerSASLCredsAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ServerSASLCredsAction.java Sat Jan 22 20:08:48 2011
@@ -26,7 +26,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.TLV;
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.BindResponse;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -71,7 +71,7 @@ public class ServerSASLCredsAction exten
 
         if ( tlv.getLength() == 0 )
         {
-            serverSaslCreds = StringTools.EMPTY_BYTES;
+            serverSaslCreds = StringConstants.EMPTY_BYTES;
         }
         else
         {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreAnyAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreAnyAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreAnyAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreAnyAction.java Sat Jan 22 20:08:48 2011
@@ -29,7 +29,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.codec.search.SubstringFilter;
 import org.apache.directory.shared.ldap.message.SearchRequest;
 import org.apache.directory.shared.ldap.message.SearchRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -78,7 +78,7 @@ public class StoreAnyAction extends Gram
             throw new DecoderException( msg );
         }
 
-        String any = StringTools.utf8ToString( tlv.getValue().getData() );
+        String any = Strings.utf8ToString(tlv.getValue().getData());
         substringFilter.addAnySubstrings( any );
 
         // We now have to get back to the nearest filter which is

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreFinalAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreFinalAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreFinalAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreFinalAction.java Sat Jan 22 20:08:48 2011
@@ -29,7 +29,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.codec.search.SubstringFilter;
 import org.apache.directory.shared.ldap.message.SearchRequest;
 import org.apache.directory.shared.ldap.message.SearchRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -78,7 +78,7 @@ public class StoreFinalAction extends Gr
             throw new DecoderException( msg );
         }
 
-        String finalValue = StringTools.utf8ToString( tlv.getValue().getData() );
+        String finalValue = Strings.utf8ToString(tlv.getValue().getData());
         substringFilter.setFinalSubstrings( finalValue );
 
         // We now have to get back to the nearest filter which is

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreReferenceAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreReferenceAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreReferenceAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreReferenceAction.java Sat Jan 22 20:08:48 2011
@@ -31,7 +31,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.message.ReferralImpl;
 import org.apache.directory.shared.ldap.message.SearchResultReference;
 import org.apache.directory.shared.ldap.util.LdapURL;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -90,7 +90,7 @@ public class StoreReferenceAction extend
         }
         else
         {
-            String urlStr = StringTools.utf8ToString( tlv.getValue().getData() );
+            String urlStr = Strings.utf8ToString(tlv.getValue().getData());
 
             try
             {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreTypeMatchingRuleAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreTypeMatchingRuleAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreTypeMatchingRuleAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/StoreTypeMatchingRuleAction.java Sat Jan 22 20:08:48 2011
@@ -29,7 +29,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.codec.search.ExtensibleMatchFilter;
 import org.apache.directory.shared.ldap.message.SearchRequest;
 import org.apache.directory.shared.ldap.message.SearchRequestImpl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -80,7 +80,7 @@ public class StoreTypeMatchingRuleAction
             ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) ( ( SearchRequestImpl ) searchRequest )
                 .getTerminalFilter();
 
-            String type = StringTools.utf8ToString( tlv.getValue().getData() );
+            String type = Strings.utf8ToString(tlv.getValue().getData());
             extensibleMatchFilter.setType( type );
 
             if ( IS_DEBUG )

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ValueAction.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ValueAction.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ValueAction.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/actions/ValueAction.java Sat Jan 22 20:08:48 2011
@@ -25,7 +25,6 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.TLV;
 import org.apache.directory.shared.ldap.codec.LdapMessageContainer;
 import org.apache.directory.shared.ldap.message.AddRequest;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -87,7 +86,7 @@ public class ValueAction extends Grammar
             }
             else
             {
-                value = StringTools.utf8ToString( tlv.getValue().getData() );
+                value = Strings.utf8ToString(tlv.getValue().getData());
 
                 if ( IS_DEBUG )
                 {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/AbstractControl.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/AbstractControl.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/AbstractControl.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/AbstractControl.java Sat Jan 22 20:08:48 2011
@@ -30,7 +30,6 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.message.control.Control;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 
 
@@ -147,7 +146,7 @@ public abstract class AbstractControl ex
     public int computeLength( int valueLength )
     {
         // The OID
-        int oidLengh = StringTools.getBytesUtf8( oid ).length;
+        int oidLengh = Strings.getBytesUtf8(oid).length;
         controlLength = 1 + TLV.getNbBytes( oidLengh ) + oidLengh;
 
         // The criticality, only if true

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/ControlImpl.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/ControlImpl.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/ControlImpl.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/ControlImpl.java Sat Jan 22 20:08:48 2011
@@ -25,7 +25,7 @@ import java.nio.ByteBuffer;
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.asn1.EncoderException;
 import org.apache.directory.shared.i18n.I18n;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -88,7 +88,7 @@ public class ControlImpl extends Abstrac
     {
         if ( value == null )
         {
-            return StringTools.EMPTY_BYTES;
+            return StringConstants.EMPTY_BYTES;
         }
 
         final byte[] copy = new byte[ value.length ];

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncmodifydn/SyncModifyDnControlGrammar.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncmodifydn/SyncModifyDnControlGrammar.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncmodifydn/SyncModifyDnControlGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/controls/replication/syncmodifydn/SyncModifyDnControlGrammar.java Sat Jan 22 20:08:48 2011
@@ -29,7 +29,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.UniversalTag;
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.ldap.message.control.replication.SyncModifyDnType;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -116,7 +116,7 @@ public final class SyncModifyDnControlGr
                     Value value = syncModifyDnControlContainer.getCurrentTLV().getValue();
 
                     // Check that the value is into the allowed interval
-                    String entryDn = StringTools.utf8ToString( value.getData() );
+                    String entryDn = Strings.utf8ToString(value.getData());
                     
                     if ( IS_DEBUG )
                     {
@@ -152,7 +152,7 @@ public final class SyncModifyDnControlGr
                     Value value = syncModifyDnControlContainer.getCurrentTLV().getValue();
 
                     // Check that the value is into the allowed interval
-                    String newSuperiorDn = StringTools.utf8ToString( value.getData() );
+                    String newSuperiorDn = Strings.utf8ToString(value.getData());
                     
                     if ( IS_DEBUG )
                     {
@@ -202,7 +202,7 @@ public final class SyncModifyDnControlGr
                     SyncModifyDnControlContainer syncModifyDnControlContainer = ( SyncModifyDnControlContainer ) container;
                     Value value = syncModifyDnControlContainer.getCurrentTLV().getValue();
 
-                    String newRdn = StringTools.utf8ToString( value.getData() );
+                    String newRdn = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {
@@ -291,7 +291,7 @@ public final class SyncModifyDnControlGr
                     SyncModifyDnControlContainer syncModifyDnControlContainer = ( SyncModifyDnControlContainer ) container;
                     Value value = syncModifyDnControlContainer.getCurrentTLV().getValue();
 
-                    String newSuperirorDn = StringTools.utf8ToString( value.getData() );
+                    String newSuperirorDn = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {
@@ -323,7 +323,7 @@ public final class SyncModifyDnControlGr
                     SyncModifyDnControlContainer syncModifyDnControlContainer = ( SyncModifyDnControlContainer ) container;
                     Value value = syncModifyDnControlContainer.getCurrentTLV().getValue();
 
-                    String newRdn = StringTools.utf8ToString( value.getData() );
+                    String newRdn = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationGrammar.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationGrammar.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationGrammar.java Sat Jan 22 20:08:48 2011
@@ -30,7 +30,6 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.DecoderException;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.name.DN;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -112,7 +111,7 @@ public class CertGenerationGrammar exten
                     CertGenerationContainer certGenContainer = ( CertGenerationContainer ) container;
                     Value value = certGenContainer.getCurrentTLV().getValue();
 
-                    String targetDN = StringTools.utf8ToString( value.getData() );
+                    String targetDN = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {
@@ -158,7 +157,7 @@ public class CertGenerationGrammar exten
                     CertGenerationContainer certGenContainer = ( CertGenerationContainer ) container;
                     Value value = certGenContainer.getCurrentTLV().getValue();
 
-                    String issuerDN = StringTools.utf8ToString( value.getData() );
+                    String issuerDN = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {
@@ -198,7 +197,7 @@ public class CertGenerationGrammar exten
                     CertGenerationContainer certGenContainer = ( CertGenerationContainer ) container;
                     Value value = certGenContainer.getCurrentTLV().getValue();
 
-                    String subjectDN = StringTools.utf8ToString( value.getData() );
+                    String subjectDN = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {
@@ -243,7 +242,7 @@ public class CertGenerationGrammar exten
                     CertGenerationContainer certGenContainer = ( CertGenerationContainer ) container;
                     Value value = certGenContainer.getCurrentTLV().getValue();
 
-                    String keyAlgorithm = StringTools.utf8ToString( value.getData() );
+                    String keyAlgorithm = Strings.utf8ToString(value.getData());
 
                     if ( IS_DEBUG )
                     {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationObject.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationObject.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationObject.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/certGeneration/CertGenerationObject.java Sat Jan 22 20:08:48 2011
@@ -26,7 +26,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.EncoderException;
 import org.apache.directory.shared.asn1.ber.tlv.UniversalTag;
 import org.apache.directory.shared.asn1.ber.tlv.Value;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 
 
 /**
@@ -66,16 +66,16 @@ public class CertGenerationObject extend
     @Override
     public int computeLength()
     {
-        int len = StringTools.getBytesUtf8( targetDN ).length;
+        int len = Strings.getBytesUtf8(targetDN).length;
         requestLength = 1 + Value.getNbBytes( len ) + len;
 
-        len = StringTools.getBytesUtf8( issuerDN ).length;
+        len = Strings.getBytesUtf8(issuerDN).length;
         requestLength += 1 + Value.getNbBytes( len ) + len;
 
-        len = StringTools.getBytesUtf8( subjectDN ).length;
+        len = Strings.getBytesUtf8(subjectDN).length;
         requestLength += 1 + Value.getNbBytes( len ) + len;
 
-        len = StringTools.getBytesUtf8( keyAlgorithm ).length;
+        len = Strings.getBytesUtf8(keyAlgorithm).length;
         requestLength += 1 + Value.getNbBytes( len ) + len;
 
         return 1 + Value.getNbBytes( requestLength ) + requestLength;

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedure.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedure.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedure.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedure.java Sat Jan 22 20:08:48 2011
@@ -33,7 +33,6 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.UniversalTag;
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.i18n.I18n;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 
 
@@ -217,7 +216,7 @@ public class StoredProcedure extends Abs
     public int computeLength()
     {
         // The language
-        byte[] languageBytes = StringTools.getBytesUtf8( language );
+        byte[] languageBytes = Strings.getBytesUtf8(language);
         
         int languageLength = 1 + TLV.getNbBytes( languageBytes.length )
             + languageBytes.length;
@@ -328,7 +327,7 @@ public class StoredProcedure extends Abs
 
         sb.append( "    StoredProcedure\n" );
         sb.append( "        Language : '" ).append( language ).append( "'\n" );
-        sb.append( "        Procedure\n" ).append( StringTools.utf8ToString( procedure ) ).append( "'\n" );
+        sb.append( "        Procedure\n" ).append( Strings.utf8ToString(procedure) ).append( "'\n" );
 
         if ( ( parameters == null ) || ( parameters.size() == 0 ) )
         {
@@ -343,7 +342,7 @@ public class StoredProcedure extends Abs
             for ( StoredProcedureParameter spParam:parameters )
             {
                 sb.append( "            type[" ).append( i ) .append( "] : '" ).
-                    append( StringTools.utf8ToString( spParam.type ) ).append( "'\n" );
+                    append( Strings.utf8ToString(spParam.type) ).append( "'\n" );
                 sb.append( "            value[" ).append( i ) .append( "] : '" ).
                     append( Strings.dumpBytes(spParam.value) ).append( "'\n" );
             }

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedureGrammar.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedureGrammar.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedureGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/extended/operations/storedProcedure/StoredProcedureGrammar.java Sat Jan 22 20:08:48 2011
@@ -31,7 +31,6 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.UniversalTag;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.codec.extended.operations.storedProcedure.StoredProcedure.StoredProcedureParameter;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -108,7 +107,7 @@ public final class StoredProcedureGramma
                     else
                     {
                         // Only this field's type is String by default
-                        String language = StringTools.utf8ToString( tlv.getValue().getData() );
+                        String language = Strings.utf8ToString(tlv.getValue().getData());
 
                         if ( LOG.isDebugEnabled() )
                         {
@@ -158,7 +157,7 @@ public final class StoredProcedureGramma
 
                     if ( LOG.isDebugEnabled() )
                     {
-                        LOG.debug( "Procedure found : " + StringTools.utf8ToString( storedProcedure.getProcedure() ) );
+                        LOG.debug( "Procedure found : " + Strings.utf8ToString(storedProcedure.getProcedure()) );
                     }
                 }
             } );

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/ExtensibleMatchFilter.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/ExtensibleMatchFilter.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/ExtensibleMatchFilter.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/ExtensibleMatchFilter.java Sat Jan 22 20:08:48 2011
@@ -28,7 +28,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.codec.LdapConstants;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 
 
 /**
@@ -213,13 +213,13 @@ public class ExtensibleMatchFilter exten
     {
         if ( matchingRule != null )
         {
-            matchingRuleBytes = StringTools.getBytesUtf8( matchingRule );
+            matchingRuleBytes = Strings.getBytesUtf8(matchingRule);
             extensibleMatchLength = 1 + TLV.getNbBytes( matchingRuleBytes.length ) + matchingRuleBytes.length;
         }
 
         if ( type != null )
         {
-            typeBytes = StringTools.getBytesUtf8( type );
+            typeBytes = Strings.getBytesUtf8(type);
             extensibleMatchLength += 1 + TLV.getNbBytes( typeBytes.length ) + typeBytes.length;
         }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/PresentFilter.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/PresentFilter.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/PresentFilter.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/PresentFilter.java Sat Jan 22 20:08:48 2011
@@ -27,7 +27,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.TLV;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.codec.LdapConstants;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 
 
 /**
@@ -103,7 +103,7 @@ public class PresentFilter extends Filte
      */
     public int computeLength()
     {
-        attributeDescriptionBytes = StringTools.getBytesUtf8( attributeDescription );
+        attributeDescriptionBytes = Strings.getBytesUtf8(attributeDescription);
         return 1 + TLV.getNbBytes( attributeDescriptionBytes.length ) + attributeDescriptionBytes.length;
     }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/SubstringFilter.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/SubstringFilter.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/SubstringFilter.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/SubstringFilter.java Sat Jan 22 20:08:48 2011
@@ -31,7 +31,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.codec.LdapConstants;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 
 
 /**
@@ -233,14 +233,14 @@ public class SubstringFilter extends Fil
     public int computeLength()
     {
         // The type
-        typeLength = StringTools.getBytesUtf8( type ).length;
+        typeLength = Strings.getBytesUtf8(type).length;
         
         substringsFilterLength = 1 + TLV.getNbBytes( typeLength ) + typeLength;
         substringsFilterSequenceLength = 0;
 
         if ( initialSubstrings != null )
         {
-            int initialLength = StringTools.getBytesUtf8( initialSubstrings ).length; 
+            int initialLength = Strings.getBytesUtf8(initialSubstrings).length;
             substringsFilterSequenceLength += 1 + TLV.getNbBytes( initialLength )
                 + initialLength;
         }
@@ -249,14 +249,14 @@ public class SubstringFilter extends Fil
         {
             for ( String any:anySubstrings )
             {
-                int anyLength = StringTools.getBytesUtf8( any ).length; 
+                int anyLength = Strings.getBytesUtf8(any).length;
                 substringsFilterSequenceLength += 1 + TLV.getNbBytes( anyLength ) + anyLength;
             }
         }
 
         if ( finalSubstrings != null )
         {
-            int finalLength = StringTools.getBytesUtf8( finalSubstrings ).length; 
+            int finalLength = Strings.getBytesUtf8(finalSubstrings).length;
             substringsFilterSequenceLength += 1 + TLV.getNbBytes( finalLength )
                 + finalLength;
         }
@@ -317,7 +317,7 @@ public class SubstringFilter extends Fil
             // The initial substring
             if ( initialSubstrings != null )
             {
-                byte[] initialBytes = StringTools.getBytesUtf8( initialSubstrings );
+                byte[] initialBytes = Strings.getBytesUtf8(initialSubstrings);
                 buffer.put( ( byte ) LdapConstants.SUBSTRINGS_FILTER_INITIAL_TAG );
                 buffer.put( TLV.getBytes( initialBytes.length ) );
                 buffer.put( initialBytes );
@@ -328,7 +328,7 @@ public class SubstringFilter extends Fil
             {
                 for ( String any:anySubstrings )
                 {
-                    byte[] anyBytes = StringTools.getBytesUtf8( any );
+                    byte[] anyBytes = Strings.getBytesUtf8(any);
                     buffer.put( ( byte ) LdapConstants.SUBSTRINGS_FILTER_ANY_TAG );
                     buffer.put( TLV.getBytes( anyBytes.length ) );
                     buffer.put( anyBytes );
@@ -338,7 +338,7 @@ public class SubstringFilter extends Fil
             // The final substring
             if ( finalSubstrings != null )
             {
-                byte[] finalBytes = StringTools.getBytesUtf8( finalSubstrings );
+                byte[] finalBytes = Strings.getBytesUtf8(finalSubstrings);
                 buffer.put( ( byte ) LdapConstants.SUBSTRINGS_FILTER_FINAL_TAG );
                 buffer.put( TLV.getBytes( finalBytes.length ) );
                 buffer.put( finalBytes );

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControl.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControl.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControl.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControl.java Sat Jan 22 20:08:48 2011
@@ -30,7 +30,7 @@ import org.apache.directory.shared.i18n.
 import org.apache.directory.shared.ldap.codec.controls.AbstractControl;
 import org.apache.directory.shared.ldap.codec.search.controls.ChangeType;
 import org.apache.directory.shared.ldap.name.DN;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Strings;
 
 
 /**
@@ -132,7 +132,7 @@ public class EntryChangeControl extends 
 
         if ( previousDn != null )
         {
-            previousDnBytes = StringTools.getBytesUtf8( previousDn.getName() );
+            previousDnBytes = Strings.getBytesUtf8(previousDn.getName());
             previousDnLength = 1 + TLV.getNbBytes( previousDnBytes.length ) + previousDnBytes.length;
         }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControlGrammar.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControlGrammar.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControlGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/entryChange/EntryChangeControlGrammar.java Sat Jan 22 20:08:48 2011
@@ -32,7 +32,6 @@ import org.apache.directory.shared.i18n.
 import org.apache.directory.shared.ldap.codec.search.controls.ChangeType;
 import org.apache.directory.shared.ldap.exception.LdapInvalidDnException;
 import org.apache.directory.shared.ldap.name.DN;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -173,7 +172,7 @@ public final class EntryChangeControlGra
 
                     try
                     {
-                        previousDn = new DN( StringTools.utf8ToString( value.getData() ) );
+                        previousDn = new DN( Strings.utf8ToString(value.getData()) );
                     }
                     catch ( LdapInvalidDnException ine )
                     {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControl.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControl.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControl.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControl.java Sat Jan 22 20:08:48 2011
@@ -29,7 +29,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.Value;
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.codec.controls.AbstractControl;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.apache.directory.shared.util.Strings;
 
 
@@ -88,7 +88,7 @@ public class PagedResultsControl extends
     {
         super( CONTROL_OID );
 
-        cookie = StringTools.EMPTY_BYTES;
+        cookie = StringConstants.EMPTY_BYTES;
         decoder = new PagedResultsControlDecoder();
     }
 

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControlGrammar.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControlGrammar.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControlGrammar.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/search/controls/pagedSearch/PagedResultsControlGrammar.java Sat Jan 22 20:08:48 2011
@@ -31,7 +31,7 @@ import org.apache.directory.shared.asn1.
 import org.apache.directory.shared.asn1.ber.tlv.IntegerDecoder;
 import org.apache.directory.shared.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.shared.i18n.I18n;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -153,7 +153,7 @@ public final class PagedResultsControlGr
 
                     if ( pagedSearchContainer.getCurrentTLV().getLength() == 0 )
                     {
-                        pagedSearchContainer.getPagedSearchControl().setCookie( StringTools.EMPTY_BYTES );
+                        pagedSearchContainer.getPagedSearchControl().setCookie( StringConstants.EMPTY_BYTES );
                     }
                     else
                     {

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/csn/Csn.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/csn/Csn.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/csn/Csn.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/csn/Csn.java Sat Jan 22 20:08:48 2011
@@ -26,7 +26,8 @@ import java.text.SimpleDateFormat;
 import java.util.Date;
 
 import org.apache.directory.shared.i18n.I18n;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.Chars;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -125,7 +126,7 @@ public class Csn implements Serializable
      */
     public Csn( String value ) throws InvalidCSNException
     {
-        if ( StringTools.isEmpty( value ) )
+        if ( Strings.isEmpty(value) )
         {
             String message = I18n.err( I18n.ERR_04114 );
             LOG.error( message );
@@ -229,7 +230,7 @@ public class Csn implements Serializable
 
         String replicaIdStr = value.substring( sepCC + 1, sepRI).trim();
         
-        if ( StringTools.isEmpty( replicaIdStr ) )
+        if ( Strings.isEmpty(replicaIdStr) )
         {
             String message = I18n.err( I18n.ERR_04123 );
             LOG.error( message );
@@ -269,7 +270,7 @@ public class Csn implements Serializable
         }
         
         csnStr = value;
-        bytes = StringTools.getBytesUtf8( csnStr );
+        bytes = Strings.getBytesUtf8(csnStr);
     }
 
 
@@ -281,7 +282,7 @@ public class Csn implements Serializable
      */
     public static boolean isValid( String value )
     {
-        if ( StringTools.isEmpty( value ) )
+        if ( Strings.isEmpty(value) )
         {
             return false;
         }
@@ -324,14 +325,14 @@ public class Csn implements Serializable
         // And add the milliseconds and microseconds now
         String millisStr = timestampStr.substring( 15, 21 );
 
-        if ( StringTools.isEmpty( millisStr ) )
+        if ( Strings.isEmpty(millisStr) )
         {
             return false;
         }
         
         for ( int i = 0; i < 6; i++ )
         {
-            if ( !StringTools.isDigit( millisStr, i ) )
+            if ( !Chars.isDigit(millisStr, i) )
             {
                 return false;
             }
@@ -356,7 +357,7 @@ public class Csn implements Serializable
     
         String changeCountStr = value.substring( sepTS + 1, sepCC ).trim();
         
-        if ( StringTools.isEmpty( changeCountStr ) )
+        if ( Strings.isEmpty(changeCountStr) )
         {
             return false;
         }
@@ -370,7 +371,7 @@ public class Csn implements Serializable
         {
             for ( int i = 0; i < 6; i++ )
             {
-                if ( !StringTools.isHex( changeCountStr, i ) )
+                if ( !Chars.isHex(changeCountStr, i) )
                 {
                     return false;
                 }
@@ -393,7 +394,7 @@ public class Csn implements Serializable
     
         String replicaIdStr = value.substring( sepCC + 1, sepRI ).trim();
         
-        if ( StringTools.isEmpty( replicaIdStr ) )
+        if ( Strings.isEmpty(replicaIdStr) )
         {
             return false;
         }
@@ -405,7 +406,7 @@ public class Csn implements Serializable
         
         for ( int i = 0; i < 3; i++ )
         {
-            if ( !StringTools.isHex( replicaIdStr, i ) )
+            if ( !Chars.isHex(replicaIdStr, i) )
             {
                 return false;
             }
@@ -435,7 +436,7 @@ public class Csn implements Serializable
 
         for ( int i = 0; i < 6; i++ )
         {
-            if ( !StringTools.isHex( operationNumberStr, i ) )
+            if ( !Chars.isHex(operationNumberStr, i) )
             {
                 return false;
             }
@@ -461,13 +462,13 @@ public class Csn implements Serializable
      */
     Csn( byte[] value )
     {
-        csnStr = StringTools.utf8ToString( value );
+        csnStr = Strings.utf8ToString(value);
         Csn csn = new Csn( csnStr );
         timestamp = csn.timestamp;
         changeCount = csn.changeCount;
         replicaId = csn.replicaId;
         operationNumber = csn.operationNumber;
-        bytes = StringTools.getBytesUtf8( csnStr );
+        bytes = Strings.getBytesUtf8(csnStr);
     }
 
 
@@ -483,7 +484,7 @@ public class Csn implements Serializable
     {
         if ( bytes == null )
         {
-            bytes = StringTools.getBytesUtf8( csnStr );
+            bytes = Strings.getBytesUtf8(csnStr);
         }
 
         byte[] copy = new byte[bytes.length];

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=1062251&r1=1062250&r2=1062251&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 Sat Jan 22 20:08:48 2011
@@ -32,7 +32,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.schema.Normalizer;
 import org.apache.directory.shared.ldap.schema.SyntaxChecker;
 import org.apache.directory.shared.ldap.schema.comparators.ByteArrayComparator;
-import org.apache.directory.shared.ldap.util.StringTools;
+import org.apache.directory.shared.util.StringConstants;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -186,7 +186,7 @@ public class BinaryValue extends Abstrac
         }
         else
         {
-            return StringTools.EMPTY_BYTES;
+            return StringConstants.EMPTY_BYTES;
         }
     }
 
@@ -547,7 +547,7 @@ public class BinaryValue extends Abstrac
      */
     public String getString()
     {
-        return StringTools.utf8ToString( wrappedValue );
+        return Strings.utf8ToString(wrappedValue);
     }
 
 
@@ -744,7 +744,7 @@ public class BinaryValue extends Abstrac
         }
         else if ( wrappedLength == 0 )
         {
-            wrappedValue = StringTools.EMPTY_BYTES;
+            wrappedValue = StringConstants.EMPTY_BYTES;
             same = true;
             normalized = true;
             normalizedValue = wrappedValue;
@@ -781,7 +781,7 @@ public class BinaryValue extends Abstrac
                     }
                     else
                     {
-                        normalizedValue = StringTools.EMPTY_BYTES;
+                        normalizedValue = StringConstants.EMPTY_BYTES;
                     }
                 }
                 else

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntry.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntry.java?rev=1062251&r1=1062250&r2=1062251&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntry.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/entry/DefaultEntry.java Sat Jan 22 20:08:48 2011
@@ -40,8 +40,8 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.name.RdnSerializer;
 import org.apache.directory.shared.ldap.schema.AttributeType;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.ldap.util.UTFUtils;
+import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -467,7 +467,7 @@ public class DefaultEntry implements Ent
 
     private String getId( String upId )
     {
-        String id = StringTools.trim( StringTools.toLowerCase( upId ) );
+        String id = Strings.trim(Strings.toLowerCase(upId));
 
         // If empty, throw an error
         if ( ( id == null ) || ( id.length() == 0 ) )
@@ -488,22 +488,22 @@ public class DefaultEntry implements Ent
      */
     private static String getUpId( String upId, AttributeType attributeType )
     {
-        String normUpId = StringTools.trim( upId );
+        String normUpId = Strings.trim(upId);
 
         if ( ( attributeType == null ) )
         {
-            if ( StringTools.isEmpty( normUpId ) )
+            if ( Strings.isEmpty(normUpId) )
             {
                 String message = I18n.err( I18n.ERR_04458 );
                 LOG.error( message );
                 throw new IllegalArgumentException( message );
             }
         }
-        else if ( StringTools.isEmpty( normUpId ) )
+        else if ( Strings.isEmpty(normUpId) )
         {
             upId = attributeType.getName();
 
-            if ( StringTools.isEmpty( upId ) )
+            if ( Strings.isEmpty(upId) )
             {
                 upId = attributeType.getOid();
             }
@@ -560,7 +560,7 @@ public class DefaultEntry implements Ent
      */
     protected AttributeType getAttributeType( String upId ) throws LdapException
     {
-        if ( StringTools.isEmpty( StringTools.trim( upId ) ) )
+        if ( Strings.isEmpty(Strings.trim(upId)) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -836,7 +836,7 @@ public class DefaultEntry implements Ent
      */
     public void add( String upId, byte[]... values ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -878,7 +878,7 @@ public class DefaultEntry implements Ent
      */
     public void add( String upId, String... values ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -920,7 +920,7 @@ public class DefaultEntry implements Ent
      */
     public void add( String upId, Value<?>... values ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -1059,7 +1059,7 @@ public class DefaultEntry implements Ent
      */
     public boolean contains( String upId ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             return false;
         }
@@ -1211,7 +1211,7 @@ public class DefaultEntry implements Ent
      */
     public boolean contains( String upId, byte[]... values )
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             return false;
         }
@@ -1246,7 +1246,7 @@ public class DefaultEntry implements Ent
      */
     public boolean contains( String upId, String... values )
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             return false;
         }
@@ -1281,7 +1281,7 @@ public class DefaultEntry implements Ent
      */
     public boolean contains( String upId, Value<?>... values )
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             return false;
         }
@@ -1388,7 +1388,7 @@ public class DefaultEntry implements Ent
      */
     public EntryAttribute put( String upId, byte[]... values )
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -1427,7 +1427,7 @@ public class DefaultEntry implements Ent
      */
     public EntryAttribute put( String upId, String... values )
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -1466,7 +1466,7 @@ public class DefaultEntry implements Ent
      */
     public EntryAttribute put( String upId, Value<?>... values )
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.error( message );
@@ -1730,7 +1730,7 @@ public class DefaultEntry implements Ent
         }
         else
         {
-            if ( !StringTools.isEmpty( upId ) )
+            if ( !Strings.isEmpty(upId) )
             {
                 AttributeType tempAT = getAttributeType( upId );
 
@@ -1780,7 +1780,7 @@ public class DefaultEntry implements Ent
         }
         else
         {
-            if ( !StringTools.isEmpty( upId ) )
+            if ( !Strings.isEmpty(upId) )
             {
                 AttributeType tempAT = getAttributeType( upId );
 
@@ -1823,7 +1823,7 @@ public class DefaultEntry implements Ent
         }
         else
         {
-            if ( !StringTools.isEmpty( upId ) )
+            if ( !Strings.isEmpty(upId) )
             {
                 AttributeType tempAT = getAttributeType( upId );
 
@@ -2185,7 +2185,7 @@ public class DefaultEntry implements Ent
      */
     public boolean remove( String upId, byte[]... values ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.info( message );
@@ -2274,7 +2274,7 @@ public class DefaultEntry implements Ent
      */
     public boolean remove( String upId, String... values ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.info( message );
@@ -2362,7 +2362,7 @@ public class DefaultEntry implements Ent
      */
     public boolean remove( String upId, Value<?>... values ) throws LdapException
     {
-        if ( StringTools.isEmpty( upId ) )
+        if ( Strings.isEmpty(upId) )
         {
             String message = I18n.err( I18n.ERR_04457_NULL_ATTRIBUTE_ID );
             LOG.info( message );



Mime
View raw message