org.camunda.bpm.engine.impl.bpmn.behavior.UserTaskActivityBehavior Java Examples

The following examples show how to use org.camunda.bpm.engine.impl.bpmn.behavior.UserTaskActivityBehavior. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: GlobalOSGiEventBridgeActivator.java    From camunda-bpm-platform-osgi with Apache License 2.0 5 votes vote down vote up
@Override
public void parseUserTask(Element userTaskElement, ScopeImpl scope, ActivityImpl activity) {
  addStartEventListener(activity);
  addEndEventListener(activity);
  UserTaskActivityBehavior activityBehavior = (UserTaskActivityBehavior) activity.getActivityBehavior();
  TaskDefinition taskDefinition = activityBehavior.getTaskDefinition();
  addTaskCreateListeners(taskDefinition);
  addTaskAssignmentListeners(taskDefinition);
  addTaskCompleteListeners(taskDefinition);
  addTaskDeleteListeners(taskDefinition);
}
 
Example #2
Source File: CdiEventSupportBpmnParseListener.java    From camunda-bpm-platform with Apache License 2.0 5 votes vote down vote up
@Override
public void parseUserTask(Element userTaskElement, ScopeImpl scope, ActivityImpl activity) {
  addStartEventListener(activity);
  addEndEventListener(activity);
  UserTaskActivityBehavior activityBehavior = (UserTaskActivityBehavior) activity.getActivityBehavior();
  TaskDefinition taskDefinition = activityBehavior.getTaskDefinition();
  addTaskCreateListeners(taskDefinition);
  addTaskAssignmentListeners(taskDefinition);
  addTaskCompleteListeners(taskDefinition);
  addTaskUpdateListeners(taskDefinition);
  addTaskDeleteListeners(taskDefinition);
}
 
Example #3
Source File: ProcessApplicationEventParseListener.java    From camunda-bpm-platform with Apache License 2.0 5 votes vote down vote up
@Override
public void parseUserTask(Element userTaskElement, ScopeImpl scope, ActivityImpl activity) {
  addStartEventListener(activity);
  addEndEventListener(activity);
  UserTaskActivityBehavior activityBehavior = (UserTaskActivityBehavior) activity.getActivityBehavior();
  TaskDefinition taskDefinition = activityBehavior.getTaskDefinition();
  addTaskCreateListeners(taskDefinition);
  addTaskAssignmentListeners(taskDefinition);
  addTaskCompleteListeners(taskDefinition);
  addTaskUpdateListeners(taskDefinition);
  addTaskDeleteListeners(taskDefinition);
}
 
Example #4
Source File: HistoryParseListener.java    From camunda-bpm-platform with Apache License 2.0 5 votes vote down vote up
public void parseUserTask(Element userTaskElement, ScopeImpl scope, ActivityImpl activity) {
  ensureHistoryLevelInitialized();
  addActivityHandlers(activity);

  if (historyLevel.isHistoryEventProduced(HistoryEventTypes.TASK_INSTANCE_CREATE, null)) {
    TaskDefinition taskDefinition = ((UserTaskActivityBehavior) activity.getActivityBehavior()).getTaskDefinition();
    taskDefinition.addBuiltInTaskListener(TaskListener.EVENTNAME_ASSIGNMENT, USER_TASK_ASSIGNMENT_HANDLER);
    taskDefinition.addBuiltInTaskListener(TaskListener.EVENTNAME_CREATE, USER_TASK_ID_HANDLER);
  }
}
 
Example #5
Source File: RegisterAllBpmnParseListener.java    From camunda-bpm-reactor with Apache License 2.0 4 votes vote down vote up
/**
 * @param activity the taskActivity
 * @return taskDefinition for activity
 */
static TaskDefinition taskDefinition(final ActivityImpl activity) {
  final UserTaskActivityBehavior activityBehavior = (UserTaskActivityBehavior) activity.getActivityBehavior();
  return activityBehavior.getTaskDefinition();
}
 
Example #6
Source File: PublishDelegateParseListener.java    From camunda-bpm-spring-boot-starter with Apache License 2.0 2 votes vote down vote up
/**
 * Retrieves task definition.
 *
 * @param activity the taskActivity
 * @return taskDefinition for activity
 */
private TaskDefinition taskDefinition(final ActivityImpl activity) {
  final UserTaskActivityBehavior activityBehavior = (UserTaskActivityBehavior) activity.getActivityBehavior();
  return activityBehavior.getTaskDefinition();
}
 
Example #7
Source File: PublishDelegateParseListener.java    From camunda-bpm-platform with Apache License 2.0 2 votes vote down vote up
/**
 * Retrieves task definition.
 *
 * @param activity the taskActivity
 * @return taskDefinition for activity
 */
private TaskDefinition taskDefinition(final ActivityImpl activity) {
  final UserTaskActivityBehavior activityBehavior = (UserTaskActivityBehavior) activity.getActivityBehavior();
  return activityBehavior.getTaskDefinition();
}