You can use the getBpmnModel (processDefinitionId) method, available in the RepositoryService interface.
- Pojo, o , . pojo , ( ). , findFlowElementsOfType ( ).
, ( , , ):
BpmnModel model = processEngine.getRepositoryService().getBpmnModel(someProcessId);
List<Process> processes = model.getProcesses();
List<UserTask> userTasks = new ArrayList<>();
for( Process p : processes ) {
userTasks.addAll( p.findFlowElementsOfType(UserTask.class))
}