]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.diagram/src/org/simantics/diagram/profile/DiagramElementGroup.java
Added hashcode/equals methods to generic profile Group implementations
[simantics/platform.git] / bundles / org.simantics.diagram / src / org / simantics / diagram / profile / DiagramElementGroup.java
index cc04927f6ef7249c7cb5a33a0620db04f48b22d5..bcbe6c7c64032bc88b336e09c9c0c83dc10f1105 100644 (file)
@@ -63,5 +63,15 @@ public abstract class DiagramElementGroup implements Group {
     }
 
     protected abstract boolean test(ReadGraph graph, Resource element) throws DatabaseException;
+    
+    @Override
+    public int hashCode() {
+        return this.getClass().hashCode();
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        return obj.getClass().equals(this.getClass());
+    }
 
 }