use of org.kie.workbench.common.stunner.bpmn.definition.BPMNViewDefinition in project kie-wb-common by kiegroup.
the class SubProcessConverter method convertSubProcess.
public Result<SubProcessPropertyWriter> convertSubProcess(Node<View<? extends BPMNViewDefinition>, ?> node) {
Result<SubProcessPropertyWriter> processRootResult = NodeMatch.fromNode(BaseSubprocess.class, SubProcessPropertyWriter.class).when(EmbeddedSubprocess.class, this::convertEmbeddedSubprocessNode).when(EventSubprocess.class, this::convertEventSubprocessNode).when(BaseAdHocSubprocess.class, this::convertAdHocSubprocessNode).when(MultipleInstanceSubprocess.class, this::convertMultipleInstanceSubprocessNode).ignore(BPMNViewDefinition.class).apply(node);
if (processRootResult.isIgnored()) {
return processRootResult;
}
DefinitionsBuildingContext subContext = context.withRootNode(node);
SubProcessPropertyWriter processRoot = processRootResult.value();
super.convertChildNodes(processRoot, subContext);
super.convertEdges(processRoot, subContext);
return processRootResult;
}
Aggregations