You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by sk...@apache.org on 2004/04/15 00:54:04 UTC

cvs commit: jakarta-commons/digester/src/java/org/apache/commons/digester/plugins Declaration.java

skitching    2004/04/14 15:54:04

  Modified:    digester/src/java/org/apache/commons/digester/plugins
                        Declaration.java
  Log:
  Removed the isEquivalent method, as it is no longer used after
  commit #1.13 to PluginDeclarationRule removed the only caller.
  
  Revision  Changes    Path
  1.14      +0 -28     jakarta-commons/digester/src/java/org/apache/commons/digester/plugins/Declaration.java
  
  Index: Declaration.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/digester/src/java/org/apache/commons/digester/plugins/Declaration.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- Declaration.java	8 Apr 2004 06:11:37 -0000	1.13
  +++ Declaration.java	14 Apr 2004 22:54:04 -0000	1.14
  @@ -213,32 +213,4 @@
               ruleLoader.addRules(digester, pattern);
           }
       }
  -
  -    /**
  -     * Returns true if the declarations are equivalent. Perhaps this would be
  -     * better as overriding equals, but then I should really override hash as
  -     * well and I can't be bothered.
  -     *
  -     * @param d the Declaration object to be compared to this object.
  -     * @return true if the specified object has the same options as this one.
  -     */
  -    public boolean isEquivalent(Declaration d) {
  -        if (different(id, d.id)) return false;
  -        if (pluginClass != d.pluginClass) return false;
  -        if (!properties.equals(d.properties)) return false;
  -
  -        // all significant fields match; these declarations are identical.
  -        return true;
  -    }
  -    
  -    /**
  -     * Returns true if the two objects are both null or both equal.
  -     */
  -    private static boolean different(Object o1, Object o2) {
  -        if (o1 == null) {
  -            return o1 == null;
  -        }
  -        
  -        return o1.equals(o2);
  -    }
   }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org