Author: nextgens
Date: 2008-04-04 05:25:41 +0000 (Fri, 04 Apr 2008)
New Revision: 18968

Modified:
   trunk/freenet/src/freenet/crypt/DSAPublicKey.java
Log:
implement DSAPublicKey.hashCode()

Modified: trunk/freenet/src/freenet/crypt/DSAPublicKey.java
===================================================================
--- trunk/freenet/src/freenet/crypt/DSAPublicKey.java   2008-04-04 05:21:19 UTC 
(rev 18967)
+++ trunk/freenet/src/freenet/crypt/DSAPublicKey.java   2008-04-04 05:25:41 UTC 
(rev 18968)
@@ -163,6 +163,13 @@
                return y.equals(o.y) && group.equals(o.group);
        }

+       public int hashCode() {
+               int hash = 5;
+               hash = 61 * hash + (this.y != null ? this.y.hashCode() : 0);
+               hash = 61 * hash + (this.group != null ? this.group.hashCode() 
: 0);
+               return hash;
+       }
+
        public boolean equals(Object o) {
                if(this == o) // Not necessary, but a very cheap optimization
                        return true;


Reply via email to