获取jbpm4中节点的类型

String owner = task_assignee_AsList.get(0).substring(2, task_assignee_AsList.get(0).length()-1);

Map<String,Object> map = new HashMap<String,Object>();
map.put(owner, "testOwner");
ProcessInstance processInstance = executionService.startProcessInstanceById(id,map);
ExecutionImpl executionImpl =(ExecutionImpl) processInstance;
ProcessDefinitionImpl processDefinitionImpl = executionImpl.getProcessDefinition();
Map<String,Activity> activitiesMap = processDefinitionImpl.getActivitiesMap();
Set<String> activitiesKeySet = activitiesMap.keySet();

for(String str : activitiesKeySet)
System.out.println(activitiesMap.get(str).getType());

你可能感兴趣的:(jbpm4)