directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r948124 - in /directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap: codec/LdapTransformer.java schema/normalizers/CachingNormalizer.java
Date Tue, 25 May 2010 17:34:51 GMT
Author: elecharny
Date: Tue May 25 17:34:50 2010
New Revision: 948124

URL: http://svn.apache.org/viewvc?rev=948124&view=rev
Log:
o Fixed some PMD warnings
o Removed dead code

Modified:
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapTransformer.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/normalizers/CachingNormalizer.java

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapTransformer.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapTransformer.java?rev=948124&r1=948123&r2=948124&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapTransformer.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/codec/LdapTransformer.java
Tue May 25 17:34:50 2010
@@ -253,11 +253,7 @@ public class LdapTransformer
         
         internalLdapResult.setResultCode( codecLdapResult.getResultCode() );
 
-        if ( codecLdapResult.getReferrals() == null )
-        {
-            
-        }
-        else
+        if ( codecLdapResult.getReferrals() != null )
         {
             ReferralImpl referral = new ReferralImpl();
             

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/normalizers/CachingNormalizer.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/normalizers/CachingNormalizer.java?rev=948124&r1=948123&r2=948124&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/normalizers/CachingNormalizer.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/normalizers/CachingNormalizer.java
Tue May 25 17:34:50 2010
@@ -25,7 +25,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.schema.Normalizer;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
 import org.apache.directory.shared.ldap.schema.registries.Registries;
-//import org.apache.directory.shared.ldap.util.SynchronizedLRUMap;
 
 
 /**
@@ -42,9 +41,6 @@ public class CachingNormalizer extends N
     /** Cache maximum size default */
     public static final int CACHE_MAX = 250;
 
-    /** Least recently used cache */
-    //private final SynchronizedLRUMap cache;
-
     /** The underlying decorated Normalizer */
     protected final Normalizer normalizer;
 
@@ -76,7 +72,6 @@ public class CachingNormalizer extends N
     {
         super( normalizer.getOid() );
         this.normalizer = normalizer;
-        //cache = new SynchronizedLRUMap( cacheSz );
     }
 
 
@@ -114,15 +109,7 @@ public class CachingNormalizer extends N
             return null;
         }
 
-        //Value<?> result = ( Value<?> ) cache.get( value );
-
-        //if ( result != null )
-        //{
-        //    return result;
-        //}
-
         Value<?> normalized = normalizer.normalize( value );
-        //cache.put( value, normalized );
         
         return normalized;
     }
@@ -138,15 +125,8 @@ public class CachingNormalizer extends N
             return null;
         }
 
-        //String normalized = ( String ) cache.get( value );
-
-        //if ( normalized != null )
-        //{
-        //    return normalized;
-        //}
-
         String normalized = normalizer.normalize( value );
-        //cache.put( value, normalized );
+
         return normalized;
     }
 



Mime
View raw message