use of org.jbpm.workflow.core.impl.DroolsConsequenceAction in project jbpm by kiegroup.
the class SubProcessNodeFactory method timer.
public SubProcessNodeFactory timer(String delay, String period, String dialect, String action) {
Timer timer = new Timer();
timer.setDelay(delay);
timer.setPeriod(period);
getSubProcessNode().addTimer(timer, new DroolsConsequenceAction(dialect, action));
return this;
}
use of org.jbpm.workflow.core.impl.DroolsConsequenceAction in project jbpm by kiegroup.
the class SubProcessNodeFactory method onExitAction.
public SubProcessNodeFactory onExitAction(String dialect, String action) {
if (getSubProcessNode().getActions(dialect) != null) {
getSubProcessNode().getActions(dialect).add(new DroolsConsequenceAction(dialect, action));
} else {
List<DroolsAction> actions = new ArrayList<DroolsAction>();
actions.add(new DroolsConsequenceAction(dialect, action));
getSubProcessNode().setActions(MilestoneNode.EVENT_NODE_EXIT, actions);
}
return this;
}
use of org.jbpm.workflow.core.impl.DroolsConsequenceAction in project jbpm by kiegroup.
the class WorkItemNodeFactory method onExitAction.
public WorkItemNodeFactory onExitAction(String dialect, String action) {
if (getWorkItemNode().getActions(dialect) != null) {
getWorkItemNode().getActions(dialect).add(new DroolsConsequenceAction(dialect, action));
} else {
List<DroolsAction> actions = new ArrayList<DroolsAction>();
actions.add(new DroolsConsequenceAction(dialect, action));
getWorkItemNode().setActions(MilestoneNode.EVENT_NODE_EXIT, actions);
}
return this;
}
use of org.jbpm.workflow.core.impl.DroolsConsequenceAction in project jbpm by kiegroup.
the class ActionNodeFactory method action.
public ActionNodeFactory action(String dialect, String action, boolean isDroolsAction) {
if (isDroolsAction) {
DroolsAction droolsAction = new DroolsAction();
droolsAction.setMetaData("Action", action);
getActionNode().setAction(droolsAction);
} else {
getActionNode().setAction(new DroolsConsequenceAction(dialect, action));
}
return this;
}
use of org.jbpm.workflow.core.impl.DroolsConsequenceAction in project jbpm by kiegroup.
the class HumanTaskNodeFactory method onEntryAction.
public HumanTaskNodeFactory onEntryAction(String dialect, String action) {
if (getHumanTaskNode().getActions(dialect) != null) {
getHumanTaskNode().getActions(dialect).add(new DroolsConsequenceAction(dialect, action));
} else {
List<DroolsAction> actions = new ArrayList<DroolsAction>();
actions.add(new DroolsConsequenceAction(dialect, action));
getHumanTaskNode().setActions(MilestoneNode.EVENT_NODE_ENTER, actions);
}
return this;
}
Aggregations