return alist;
}
public List<PositionedHistoricTaskInstance> getTraversedTasks() {
ArrayList<PositionedHistoricTaskInstance> alist = new ArrayList<PositionedHistoricTaskInstance>();
ProcessInstance processInstance = getCurrentProcessInstance();
if (processInstance != null) {
DiagramLayout processDiagramLayout = repositoryService.getProcessDiagramLayout(processInstance.getProcessDefinitionId());
List<HistoricTaskInstance> hlist = historyService.createHistoricTaskInstanceQuery().processInstanceId(processInstance.getId()).orderByHistoricActivityInstanceStartTime().asc().list();
for (HistoricTaskInstance htask : hlist) {
if (htask.getEndTime() != null) {
PositionedHistoricTaskInstance ptask = new PositionedHistoricTaskInstance(htask, processDiagramLayout.getNode(htask.getTaskDefinitionKey()));
alist.add(ptask);
}