use of org.kie.workbench.common.stunner.bpmn.definition.property.task.IsAsync in project kie-wb-common by kiegroup.
the class CallActivityConverter method convert.
public BpmnNode convert(CallActivity activity) {
Node<View<ReusableSubprocess>, Edge> node = factoryManager.newNode(activity.getId(), ReusableSubprocess.class);
ReusableSubprocess definition = node.getContent().getDefinition();
ActivityPropertyReader p = propertyReaderFactory.of(activity);
definition.setGeneral(new BPMNGeneralSet(new Name(p.getName()), new Documentation(p.getDocumentation())));
definition.setExecutionSet(new ReusableSubprocessTaskExecutionSet(new CalledElement(activity.getCalledElement()), new Independent(p.isIndependent()), new WaitForCompletion(p.isWaitForCompletion()), new IsAsync(p.isAsync())));
definition.setDataIOSet(new DataIOSet(p.getAssignmentsInfo()));
node.getContent().setBounds(p.getBounds());
definition.setSimulationSet(p.getSimulationSet());
definition.setDimensionsSet(p.getRectangleDimensionsSet());
definition.setFontSet(p.getFontSet());
definition.setBackgroundSet(p.getBackgroundSet());
return BpmnNode.of(node);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.IsAsync in project kie-wb-common by kiegroup.
the class TaskConverter method userTask.
private BpmnNode userTask(org.eclipse.bpmn2.UserTask task) {
Node<View<UserTask>, Edge> node = factoryManager.newNode(task.getId(), UserTask.class);
UserTask definition = node.getContent().getDefinition();
UserTaskPropertyReader p = propertyReaderFactory.of(task);
definition.setGeneral(new TaskGeneralSet(new Name(p.getName()), new Documentation(p.getDocumentation())));
definition.setSimulationSet(p.getSimulationSet());
definition.setExecutionSet(new UserTaskExecutionSet(new TaskName(p.getTaskName()), p.getActors(), new Groupid(p.getGroupid()), p.getAssignmentsInfo(), new IsAsync(p.isAsync()), new Skippable(p.isSkippable()), new Priority(p.getPriority()), new Subject(p.getSubject()), new Description(p.getDescription()), new CreatedBy(p.getCreatedBy()), new AdHocAutostart(p.isAdHocAutostart()), new OnEntryAction(p.getOnEntryAction()), new OnExitAction(p.getOnExitAction())));
node.getContent().setBounds(p.getBounds());
definition.setDimensionsSet(p.getRectangleDimensionsSet());
definition.setBackgroundSet(p.getBackgroundSet());
definition.setFontSet(p.getFontSet());
return BpmnNode.of(node);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.IsAsync in project kie-wb-common by kiegroup.
the class TaskConverter method businessRuleTask.
private BpmnNode businessRuleTask(org.eclipse.bpmn2.BusinessRuleTask task) {
Node<View<BusinessRuleTask>, Edge> node = factoryManager.newNode(task.getId(), BusinessRuleTask.class);
BusinessRuleTask definition = node.getContent().getDefinition();
BusinessRuleTaskPropertyReader p = propertyReaderFactory.of(task);
definition.setGeneral(new TaskGeneralSet(new Name(p.getName()), new Documentation(p.getDocumentation())));
definition.setDataIOSet(new DataIOSet(p.getAssignmentsInfo()));
definition.setExecutionSet(new BusinessRuleTaskExecutionSet(new RuleFlowGroup(p.getRuleFlowGroup()), new OnEntryAction(p.getOnEntryAction()), new OnExitAction(p.getOnExitAction()), new IsAsync(p.isAsync()), new AdHocAutostart(p.isAdHocAutoStart())));
definition.setSimulationSet(p.getSimulationSet());
node.getContent().setBounds(p.getBounds());
definition.setDimensionsSet(p.getRectangleDimensionsSet());
definition.setBackgroundSet(p.getBackgroundSet());
definition.setFontSet(p.getFontSet());
return BpmnNode.of(node);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.IsAsync in project kie-wb-common by kiegroup.
the class TaskConverter method scriptTask.
private BpmnNode scriptTask(org.eclipse.bpmn2.ScriptTask task) {
Node<View<ScriptTask>, Edge> node = factoryManager.newNode(task.getId(), ScriptTask.class);
ScriptTask definition = node.getContent().getDefinition();
ScriptTaskPropertyReader p = propertyReaderFactory.of(task);
definition.setGeneral(new TaskGeneralSet(new Name(p.getName()), new Documentation(p.getDocumentation())));
definition.setExecutionSet(new ScriptTaskExecutionSet(new Script(p.getScript()), new IsAsync(p.isAsync())));
node.getContent().setBounds(p.getBounds());
definition.setDimensionsSet(p.getRectangleDimensionsSet());
definition.setBackgroundSet(p.getBackgroundSet());
definition.setFontSet(p.getFontSet());
definition.setSimulationSet(p.getSimulationSet());
return BpmnNode.of(node);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.IsAsync in project kie-wb-common by kiegroup.
the class ScriptTaskConverter method convert.
public Node<? extends View<? extends BPMNViewDefinition>, ?> convert(org.eclipse.bpmn2.ScriptTask task) {
Node<View<ScriptTask>, Edge> node = factoryManager.newNode(task.getId(), ScriptTask.class);
ScriptTask definition = node.getContent().getDefinition();
ScriptTaskPropertyReader p = propertyReaderFactory.of(task);
definition.setGeneral(new TaskGeneralSet(new Name(p.getName()), new Documentation(p.getDocumentation())));
definition.setExecutionSet(new ScriptTaskExecutionSet(new Script(p.getScript()), new IsAsync(p.isAsync())));
node.getContent().setBounds(p.getBounds());
definition.setDimensionsSet(p.getRectangleDimensionsSet());
definition.setBackgroundSet(p.getBackgroundSet());
definition.setFontSet(p.getFontSet());
definition.setSimulationSet(p.getSimulationSet());
return node;
}
Aggregations