// public TaskDef(ExpertDef parent, AstNodeKind kind, Token token, TaskStubDef stubDef, TaskProcedureDef procDef) : base(kind, token) { Parent = parent; stubDef.Parent = procDef.Parent = this; StubDef = stubDef; ProcedureDef = procDef; Atomicity = Atomicity.StronglyNonAtomic; }
public static TaskDef Create(ExpertDef parent, AstNodeKind kind, Token token, TaskStubDef stubDef, TaskProcedureDef procDef) { TaskDef def = new TaskDef(parent, kind, token, stubDef, procDef); if (kind != AstNodeKind.InnerTaskDef) { def.AddChild(stubDef); } def.AddChild(procDef); parent.AddChild(def); return(def); }
public TaskDef CreateSubtaskDef() { TaskDef taskDef = ExpertDef.CreateTaskDef(new Token(Token.ToString() + "_" + ++SubtaskCount), AstNodeKind.InnerTaskDef); return(taskDef); }