directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r1003772 - in /directory/shared/trunk/ldap/src: checkstyle/ main/java/org/apache/directory/shared/ldap/schema/
Date Sat, 02 Oct 2010 10:59:46 GMT
Author: seelmann
Date: Sat Oct  2 10:59:46 2010
New Revision: 1003772

URL: http://svn.apache.org/viewvc?rev=1003772&view=rev
Log:
Fix checkstyle errors, exclude EqualsHashCode check for schema classes

Modified:
    directory/shared/trunk/ldap/src/checkstyle/suppressions.xml
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/DITStructureRule.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LdapComparator.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LoadableSchemaObject.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/NameForm.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/Normalizer.java
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/SyntaxChecker.java

Modified: directory/shared/trunk/ldap/src/checkstyle/suppressions.xml
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/checkstyle/suppressions.xml?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/checkstyle/suppressions.xml (original)
+++ directory/shared/trunk/ldap/src/checkstyle/suppressions.xml Sat Oct  2 10:59:46 2010
@@ -26,4 +26,10 @@
 <suppressions>
     <!-- UnixCrypt is from external, no formatting is applied -->
     <suppress files="UnixCrypt.java" checks="[A-Za-z0-9]" />
+    
+    <suppress files="SyntaxChecker.java" checks="EqualsHashCode" />
+    <suppress files="Normalizer.java" checks="EqualsHashCode" />
+    <suppress files="LoadableSchemaObject.java" checks="EqualsHashCode" />
+    <suppress files="LdapComparator.java" checks="EqualsHashCode" />
+    <suppress files="DITStructureRule.java" checks="EqualsHashCode" />
 </suppressions>

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/DITStructureRule.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/DITStructureRule.java?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/DITStructureRule.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/DITStructureRule.java
Sat Oct  2 10:59:46 2010
@@ -129,7 +129,7 @@ public class DITStructureRule extends Ab
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.form = form;
@@ -157,7 +157,7 @@ public class DITStructureRule extends Ab
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.ruleId = ruleId;
@@ -185,7 +185,7 @@ public class DITStructureRule extends Ab
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.superRules = superRules;
@@ -204,14 +204,17 @@ public class DITStructureRule extends Ab
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         superRules.add( superRule );
     }
 
 
     /**
-     * The DSR does not have an OID, so throw an exception
+     * The DIT structure rule does not have an OID, so this implementations always throws
an exception.
+     * 
+     * {@inheritDoc}
      */
+    @Override
     public String getOid()
     {
         throw new NotImplementedException();
@@ -219,8 +222,9 @@ public class DITStructureRule extends Ab
 
 
     /**
-     * @see Object#toString()
+     * {@inheritDoc}
      */
+    @Override
     public String toString()
     {
         return objectType + " " + DescriptionUtils.getDescription( this );
@@ -228,7 +232,7 @@ public class DITStructureRule extends Ab
 
 
     /**
-     * Copy a DITStructureRule
+     * {@inheritDoc}
      */
     public DITStructureRule copy()
     {
@@ -243,9 +247,9 @@ public class DITStructureRule extends Ab
         // Copy the form
         copy.form = form;
 
-        for ( int ruleId : superRules )
+        for ( int superRule : superRules )
         {
-            copy.superRules.add( ruleId );
+            copy.superRules.add( superRule );
         }
 
         return copy;
@@ -253,10 +257,11 @@ public class DITStructureRule extends Ab
 
 
     /**
-     * @see Object#equals(Object)
+     * {@inheritDoc}
      */
     @Override
-    @SuppressWarnings("PMD.UnusedLocalVariable") // Remove me when the TODO is fixed 
+    @SuppressWarnings("PMD.UnusedLocalVariable")
+    // Remove me when the TODO is fixed 
     public boolean equals( Object o )
     {
         if ( !super.equals( o ) )

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LdapComparator.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LdapComparator.java?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LdapComparator.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LdapComparator.java
Sat Oct  2 10:59:46 2010
@@ -19,8 +19,10 @@
  */
 package org.apache.directory.shared.ldap.schema;
 
+
 import java.util.Comparator;
 
+
 /**
  * An class used for Comparator. It inherits from the general AbstractAdsSchemaObject class.
It
  * also implements the Comparator interface
@@ -32,7 +34,7 @@ public abstract class LdapComparator<T> 
     /** The serialversionUID */
     private static final long serialVersionUID = 1L;
 
-    
+
     /**
      * Create a new instance of a Comparator
      * @param oid The associated OID
@@ -42,7 +44,7 @@ public abstract class LdapComparator<T> 
         super( SchemaObjectType.COMPARATOR, oid );
     }
 
-    
+
     /**
      * Store the SchemaManager in this instance. It may be necessary for some
      * comparator which needs to have access to the oidNormalizer Map.
@@ -53,11 +55,12 @@ public abstract class LdapComparator<T> 
     {
         // Do nothing (general case).
     }
-    
-    
+
+
     /**
-     * @see Object#equals()
+     * {@inheritDoc}
      */
+    @Override
     public boolean equals( Object o )
     {
         if ( !super.equals( o ) )
@@ -68,10 +71,11 @@ public abstract class LdapComparator<T> 
         return o instanceof LdapComparator<?>;
     }
 
-    
+
     /**
-     * @see Object#toString()
+     * {@inheritDoc}
      */
+    @Override
     public String toString()
     {
         return objectType + " " + DescriptionUtils.getDescription( this );

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LoadableSchemaObject.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LoadableSchemaObject.java?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LoadableSchemaObject.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/LoadableSchemaObject.java
Sat Oct  2 10:59:46 2010
@@ -22,7 +22,6 @@ package org.apache.directory.shared.ldap
 
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.exception.LdapException;
-
 import org.apache.directory.shared.ldap.schema.registries.Registries;
 import org.apache.directory.shared.ldap.util.StringTools;
 
@@ -41,10 +40,10 @@ public abstract class LoadableSchemaObje
     private static final long serialVersionUID = 1L;
 
     /** The Full Qualified Class Name */
-    private String            fqcn;
+    private String fqcn;
 
     /** The base64 encoded bytecode for this schema */
-    private String            bytecode;
+    private String bytecode;
 
 
     /**
@@ -97,7 +96,7 @@ public abstract class LoadableSchemaObje
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.bytecode = bytecode;
@@ -125,7 +124,7 @@ public abstract class LoadableSchemaObje
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.fqcn = fqcn;
@@ -152,7 +151,7 @@ public abstract class LoadableSchemaObje
 
 
     /**
-     * @see Object#equals()
+     * {@inheritDoc}
      */
     @Override
     public boolean equals( Object o )

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/NameForm.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/NameForm.java?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/NameForm.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/NameForm.java
Sat Oct  2 10:59:46 2010
@@ -26,7 +26,6 @@ import java.util.List;
 
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.exception.LdapException;
-
 import org.apache.directory.shared.ldap.schema.registries.AttributeTypeRegistry;
 import org.apache.directory.shared.ldap.schema.registries.Registries;
 
@@ -211,7 +210,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.structuralObjectClassOid = structuralObjectClassOid;
@@ -230,7 +229,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.structuralObjectClass = structuralObjectClass;
@@ -277,7 +276,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.mustAttributeTypeOids = mustAttributeTypeOids;
@@ -296,7 +295,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.mustAttributeTypes = mustAttributeTypes;
@@ -323,7 +322,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             mustAttributeTypeOids.add( oid );
@@ -342,7 +341,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly && !mustAttributeTypeOids.contains( attributeType.getOid()
) )
         {
             mustAttributeTypes.add( attributeType );
@@ -389,7 +388,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.mayAttributeTypeOids = mayAttributeTypeOids;
@@ -408,7 +407,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             this.mayAttributeTypes = mayAttributeTypes;
@@ -435,7 +434,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly )
         {
             mayAttributeTypeOids.add( oid );
@@ -454,7 +453,7 @@ public class NameForm extends AbstractSc
         {
             throw new UnsupportedOperationException( I18n.err( I18n.ERR_04441, getName()
) );
         }
-        
+
         if ( !isReadOnly && !mayAttributeTypeOids.contains( attributeType.getOid()
) )
         {
             mayAttributeTypes.add( attributeType );
@@ -518,7 +517,8 @@ public class NameForm extends AbstractSc
      * @see Object#equals(Object)
      */
     @Override
-    @SuppressWarnings("PMD.UnusedLocalVariable") // Remove me when the TODO is fixed 
+    @SuppressWarnings("PMD.UnusedLocalVariable")
+    // Remove me when the TODO is fixed 
     public boolean equals( Object o )
     {
         if ( !super.equals( o ) )

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/Normalizer.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/Normalizer.java?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/Normalizer.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/Normalizer.java
Sat Oct  2 10:59:46 2010
@@ -92,7 +92,7 @@ public abstract class Normalizer extends
 
 
     /**
-     * @see Object#equals()
+     * {@inheritDoc}
      */
     @Override
     public boolean equals( Object o )
@@ -107,8 +107,9 @@ public abstract class Normalizer extends
 
 
     /**
-     * @see Object#toString()
+     * {@inheritDoc}
      */
+    @Override
     public String toString()
     {
         return objectType + " " + DescriptionUtils.getDescription( this );

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/SyntaxChecker.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/SyntaxChecker.java?rev=1003772&r1=1003771&r2=1003772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/SyntaxChecker.java
(original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/schema/SyntaxChecker.java
Sat Oct  2 10:59:46 2010
@@ -39,6 +39,7 @@ public abstract class SyntaxChecker exte
     /** The serialversionUID */
     private static final long serialVersionUID = 1L;
 
+
     /**
      * The SyntaxChecker base constructor
      * @param oid The associated OID
@@ -94,10 +95,10 @@ public abstract class SyntaxChecker exte
     {
         // Do nothing (general case).
     }
-    
-    
+
+
     /**
-     * @see Object#equals()
+     * {@inheritDoc}
      */
     @Override
     public boolean equals( Object o )
@@ -110,10 +111,11 @@ public abstract class SyntaxChecker exte
         return o instanceof SyntaxChecker;
     }
 
-    
+
     /**
-     * @see Object#toString()
+     * {@inheritDoc}
      */
+    @Override
     public String toString()
     {
         return objectType + " " + DescriptionUtils.getDescription( this );



Mime
View raw message