private boolean isSkeleton;
private boolean isCombinationNode;
private boolean isSharedNode;
+ private boolean isMergeNode;
public HNode() {
this.isSkeleton = false;
this.isCombinationNode = false;
this.isSharedNode = false;
+ this.isMergeNode = false;
+ }
+
+ public boolean isMergeNode() {
+ return isMergeNode;
+ }
+
+ public void setMergeNode(boolean isMergeNode) {
+ this.isMergeNode = isMergeNode;
}
public HNode(String name) {
return false;
}
+ public String getNamePropertyString() {
+ return toString().substring(1, toString().length() - 1);
+ }
+
public String toString() {
- String isShared = "";
+
+ String properties = "";
+
if (isSharedNode()) {
- isShared = "*";
+ properties += "*";
}
- return "[Node::" + name + isShared + "]";
+
+ if (isCombinationNode()) {
+ properties += "C";
+ }
+
+ if (isSkeleton()) {
+ properties += "S";
+ }
+
+ if (properties.length() > 0) {
+ properties = "(" + properties + ")";
+ }
+
+ return "[" + name + properties + "]";
}
public Descriptor getDescriptor() {