[Mulgara-svn] r463 - trunk/src/jar/query/java/org/mulgara/query

pag at mulgara.org pag at mulgara.org
Fri Oct 5 19:02:52 UTC 2007


Author: pag
Date: 2007-10-05 14:02:51 -0500 (Fri, 05 Oct 2007)
New Revision: 463

Modified:
   trunk/src/jar/query/java/org/mulgara/query/ModelOperation.java
Log:
Inverted test in the equals method

Modified: trunk/src/jar/query/java/org/mulgara/query/ModelOperation.java
===================================================================
--- trunk/src/jar/query/java/org/mulgara/query/ModelOperation.java	2007-10-03 22:05:54 UTC (rev 462)
+++ trunk/src/jar/query/java/org/mulgara/query/ModelOperation.java	2007-10-05 19:02:51 UTC (rev 463)
@@ -150,19 +150,13 @@
    * @return RETURNED VALUE TO DO
    */
   public boolean equals(Object m) {
+    if (m == null) return false;
+    if (m == this) return true;
 
-    if ( (m == null) || m.getClass().equals(getClass())) {
+    Class<?> type = m.getClass();
+    if (!type.equals(getClass())) return false;
 
-      return false;
-    }
 
-    if (m == this) {
-
-      return true;
-    }
-
-    Class type = m.getClass();
-
     Set otherExpressions = new HashSet();
     ( (ModelOperation) m).flattenExpression(otherExpressions, type);
 




More information about the Mulgara-svn mailing list