commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simonetrip...@apache.org
Subject svn commit: r898981 - in /commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations: person/Person.java servletbean/ServletBean.java
Date Wed, 13 Jan 2010 22:37:14 GMT
Author: simonetripodi
Date: Wed Jan 13 22:37:13 2010
New Revision: 898981

URL: http://svn.apache.org/viewvc?rev=898981&view=rev
Log:
removed useless hashCode() method on test POJOs since it is not relevant on tests

Modified:
    commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/person/Person.java
    commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/servletbean/ServletBean.java

Modified: commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/person/Person.java
URL: http://svn.apache.org/viewvc/commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/person/Person.java?rev=898981&r1=898980&r2=898981&view=diff
==============================================================================
--- commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/person/Person.java
(original)
+++ commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/person/Person.java
Wed Jan 13 22:37:13 2010
@@ -80,18 +80,6 @@
     }
 
     @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = 1;
-        result = prime * result
-                + ((category == null) ? 0 : category.hashCode());
-        result = prime * result + ((emails == null) ? 0 : emails.hashCode());
-        result = prime * result + id;
-        result = prime * result + ((name == null) ? 0 : name.hashCode());
-        return result;
-    }
-
-    @Override
     public boolean equals(Object obj) {
         if (this == obj)
             return true;

Modified: commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/servletbean/ServletBean.java
URL: http://svn.apache.org/viewvc/commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/servletbean/ServletBean.java?rev=898981&r1=898980&r2=898981&view=diff
==============================================================================
--- commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/servletbean/ServletBean.java
(original)
+++ commons/sandbox/at-digester/trunk/src/test/org/apache/commons/digester/annotations/servletbean/ServletBean.java
Wed Jan 13 22:37:13 2010
@@ -67,19 +67,6 @@
     }
 
     @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = 1;
-        result = prime * result
-                + ((initParams == null) ? 0 : initParams.hashCode());
-        result = prime * result
-                + ((servletClass == null) ? 0 : servletClass.hashCode());
-        result = prime * result
-                + ((servletName == null) ? 0 : servletName.hashCode());
-        return result;
-    }
-
-    @Override
     public boolean equals(Object obj) {
         if (this == obj)
             return true;



Mime
View raw message