use of org.camunda.bpm.engine.impl.cmmn.behavior.CmmnActivityBehavior in project camunda-bpm-platform by camunda.
the class HumanTaskPlanItemHandlerTest method testActivityBehavior.
@Test
public void testActivityBehavior() {
// given: a planItem
// when
CmmnActivity activity = handler.handleElement(planItem, context);
// then
CmmnActivityBehavior behavior = activity.getActivityBehavior();
assertTrue(behavior instanceof HumanTaskActivityBehavior);
}
use of org.camunda.bpm.engine.impl.cmmn.behavior.CmmnActivityBehavior in project camunda-bpm-platform by camunda.
the class CaseHandlerTest method testActivityBehavior.
@Test
public void testActivityBehavior() {
// given: a case
// when
CmmnActivity activity = handler.handleElement(caseDefinition, context);
// then
CmmnActivityBehavior behavior = activity.getActivityBehavior();
assertNull(behavior);
}
use of org.camunda.bpm.engine.impl.cmmn.behavior.CmmnActivityBehavior in project camunda-bpm-platform by camunda.
the class ItemHandler method createActivity.
protected CmmnActivity createActivity(CmmnElement element, CmmnHandlerContext context) {
String id = element.getId();
CmmnActivity parent = context.getParent();
CmmnActivity newActivity = null;
if (parent != null) {
newActivity = parent.createActivity(id);
} else {
CmmnCaseDefinition caseDefinition = context.getCaseDefinition();
newActivity = new CmmnActivity(id, caseDefinition);
}
newActivity.setCmmnElement(element);
CmmnActivityBehavior behavior = getActivityBehavior();
newActivity.setActivityBehavior(behavior);
return newActivity;
}
use of org.camunda.bpm.engine.impl.cmmn.behavior.CmmnActivityBehavior in project camunda-bpm-platform by camunda.
the class AtomicOperationCaseExecutionStart method eventNotificationsStarted.
protected CmmnExecution eventNotificationsStarted(CmmnExecution execution) {
CmmnActivityBehavior behavior = getActivityBehavior(execution);
behavior.onStart(execution);
execution.setCurrentState(ACTIVE);
return execution;
}
use of org.camunda.bpm.engine.impl.cmmn.behavior.CmmnActivityBehavior in project camunda-bpm-platform by camunda.
the class AbstractAtomicOperationCaseExecutionResume method postTransitionNotification.
protected void postTransitionNotification(CmmnExecution execution) {
CmmnActivityBehavior behavior = getActivityBehavior(execution);
behavior.resumed(execution);
}
Aggregations