public void revisitLanes(Definitions def) { List<RootElement> rootElements = def.getRootElements(); for (RootElement root : rootElements) { if (root instanceof Process) { Process process = (Process) root; if ((process.getLaneSets() == null || process.getLaneSets().size() < 1) && _lanes.size() > 0) { LaneSet ls = Bpmn2Factory.eINSTANCE.createLaneSet(); for (Lane lane : _lanes) { ls.getLanes().add(lane); List<FlowNode> laneFlowNodes = lane.getFlowNodeRefs(); for (FlowNode fl : laneFlowNodes) { process.getFlowElements().add(fl); } } process.getLaneSets().add(ls); } } } }
public void addLaneSet(Collection<LanePropertyWriter> lanes) { if (lanes.isEmpty()) { return; } LaneSet laneSet = bpmn2.createLaneSet(); List<org.eclipse.bpmn2.Lane> laneList = laneSet.getLanes(); lanes.forEach(l -> laneList.add(l.getElement())); process.getLaneSets().add(laneSet); lanes.forEach(l -> { this.childElements.put(l.getElement().getId(), l); addChildShape(l.getShape()); }); }
public BpmnNode convertProcess() { Process process = delegate.definitionResolver.getProcess(); String definitionsId = delegate.definitionResolver.getDefinitions().getId(); BpmnNode processRoot = convertProcessNode(definitionsId, process); Map<String, BpmnNode> nodes = delegate.convertChildNodes(processRoot, process.getFlowElements(), process.getLaneSets()); delegate.convertEdges(processRoot, Stream.concat(process.getFlowElements().stream(), process.getArtifacts().stream()).collect(Collectors.toList()), nodes); return processRoot; }
for (LaneSet laneSet : process.getLaneSets()) { for (Lane lane : laneSet.getLanes()) {
for (BaseElement child : childElements) { if (child instanceof Lane) { if (((Process) baseElt).getLaneSets().isEmpty()) { ((Process) baseElt).getLaneSets().add(Bpmn2Factory.eINSTANCE.createLaneSet()); ((Process) baseElt).getLaneSets().get(0).getLanes().add((Lane) child); addLaneFlowNodes((Process) baseElt, (Lane) child);
if (process.getLaneSets() != null && process.getLaneSets().size() > 0) { for (LaneSet ls : process.getLaneSets()) { for (Lane lane : ls.getLanes()) { createBpmnShapeForElement(factory,
Process process = (Process) root; if (sq.getSourceRef() != null && sq.getTargetRef() != null) { if (process.getLaneSets() != null && process.getLaneSets().size() > 0) { for (LaneSet ls : process.getLaneSets()) { for (Lane newLane : ls.getLanes()) { List<FlowNode> laneFlowNodes = newLane.getFlowNodeRefs();