Expansion expansion = (Expansion) parent.getPlanElement(); NewWorkflow wf = (NewWorkflow) expansion.getWorkflow(); Iterator subtasksIT = subtasks.iterator(); while(subtasksIT.hasNext()) { Task task = (Task) subtasksIT.next() dfPlugin.publishAdd(task); wf.addTask(task); } dfPlugin.publishChange(expansion);
Expansion expansion = (Expansion) parent.getPlanElement(); NewWorkflow wf = (NewWorkflow) expansion.getWorkflow(); Iterator subtasksIT = subtasks.iterator(); while(subtasksIT.hasNext()) { Task task = (Task) subtasksIT.next(); dfPlugin.publishAdd(task); wf.addTask(task);
    protected void addToAndPublishExpansion(Task parent, Collection subtasks) {	Expansion expansion = (Expansion) parent.getPlanElement();	NewWorkflow wf = (NewWorkflow) expansion.getWorkflow();	Iterator subtasksIT = subtasks.iterator();	while(subtasksIT.hasNext()) {	    Task task = (Task) subtasksIT.next()	    dfPlugin.publishAdd(task);	    wf.addTask(task);	}	dfPlugin.publishChange(expansion);    }