import java.util.*;
import Util.GraphNode;
-public class EGTaskNode extends TaskNode {
+public class EGTaskNode extends GraphNode {
private boolean source=false;
private FlagState fs;
private FlagState postfs;
private TaskDescriptor td;
private int index;
+ private String name;
+ private int uid;
+ private static int nodeid;
public EGTaskNode(String name, TaskDescriptor td, FlagState postfs){
this(name, null, td, -1, postfs);
}
public EGTaskNode(String name, FlagState fs, TaskDescriptor td, int index, FlagState postfs){
- super(name);
+ this.name=name;
+ this.uid=nodeid++;
this.fs = fs;
this.td = td;
this.index=index;
this.postfs=postfs;
}
+
+ public String getTextLabel() {
+ return "Task "+getName()+"["+fs+"]->["+postfs+"]";
+ }
+
+ public String getName() {
+ return name;
+ }
+
+ public String getLabel() {
+ return "N"+uid;
+ }
public int getIndex() {
return index;
}
+ public String toString() {
+ return getTextLabel();
+ }
+
public FlagState getPostFS() {
return postfs;
}