use of org.jbpm.kie.services.impl.admin.commands.ListNodesCommand in project jbpm by kiegroup.
the class ProcessInstanceAdminServiceImpl method getProcessNodes.
@Override
public Collection<ProcessNode> getProcessNodes(long processInstanceId) throws ProcessInstanceNotFoundException {
ProcessInstanceDesc pi = runtimeDataService.getProcessInstanceById(processInstanceId);
if (pi == null) {
throw new ProcessInstanceNotFoundException("Process instance with id " + processInstanceId + " not found");
}
Collection<ProcessNode> nodes = processService.execute(pi.getDeploymentId(), ProcessInstanceIdContext.get(processInstanceId), new ListNodesCommand(processInstanceId));
return nodes;
}
Aggregations