]> gerrit.simantics Code Review - simantics/interop.git/blobdiff - org.simantics.interop.update/src/org/simantics/interop/update/model/UpdateNode.java
Moved label generation to separate init() method
[simantics/interop.git] / org.simantics.interop.update / src / org / simantics / interop / update / model / UpdateNode.java
index cc996a28239159d5ef94d666f49f2a9c1bae6f1f..486b3a1ec204b882db7dbd0e86c4d4addeb9b66c 100644 (file)
@@ -30,7 +30,7 @@ public class UpdateNode {
                this.status = status;
                this.op = op;
                this.r = op.getResource();
-               this.label = getLabel(g, r);
+               init(g);
        }
        
        public UpdateNode(ReadGraph g, UpdateStatus status, Resource r) throws DatabaseException {
@@ -38,6 +38,10 @@ public class UpdateNode {
                this.status = status;
                this.op = null;
                this.r = r;
+               init(g);
+       }
+       
+       protected void init(ReadGraph g) throws DatabaseException {
                this.label = getLabel(g, r);
        }