use of org.kie.workbench.common.stunner.bpmn.backend.converters.tostunner.properties.BusinessRuleTaskPropertyReader 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);
}
Aggregations