accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From medi...@apache.org
Subject svn commit: r1410966 - /accumulo/trunk/core/src/main/java/org/apache/accumulo/core/client/mock/MockTable.java
Date Sun, 18 Nov 2012 19:35:02 GMT
Author: medined
Date: Sun Nov 18 19:35:01 2012
New Revision: 1410966

URL: http://svn.apache.org/viewvc?rev=1410966&view=rev
Log:
ACCUMULO-755: Run Findbugs - added instanceof test to MockMemKey.equals

Modified:
    accumulo/trunk/core/src/main/java/org/apache/accumulo/core/client/mock/MockTable.java

Modified: accumulo/trunk/core/src/main/java/org/apache/accumulo/core/client/mock/MockTable.java
URL: http://svn.apache.org/viewvc/accumulo/trunk/core/src/main/java/org/apache/accumulo/core/client/mock/MockTable.java?rev=1410966&r1=1410965&r2=1410966&view=diff
==============================================================================
--- accumulo/trunk/core/src/main/java/org/apache/accumulo/core/client/mock/MockTable.java
(original)
+++ accumulo/trunk/core/src/main/java/org/apache/accumulo/core/client/mock/MockTable.java
Sun Nov 18 19:35:01 2012
@@ -53,9 +53,8 @@ public class MockTable {
     }
     
     @Override
-    public boolean equals(Object obj) {
-      MockMemKey other = (MockMemKey) obj;
-      return super.equals(other) && count == other.count;
+    public boolean equals(Object other) {
+      return (other instanceof MockMemKey) && super.equals((MockMemKey)other) &&
count == ((MockMemKey)other).count;
     }
     
     @Override



Mime
View raw message