public Lane getLane(String id) { Lane foundLane = null; if (StringUtils.isNotEmpty(id)) { for (Process process : processes) { for (Lane lane : process.getLanes()) { if (id.equals(lane.getId())) { foundLane = lane; break; } } if (foundLane != null) { break; } } } return foundLane; }
public Lane getLane(String id) { Lane foundLane = null; if (StringUtils.isNotEmpty(id)) { for (Process process : processes) { for (Lane lane : process.getLanes()) { if (id.equals(lane.getId())) { foundLane = lane; break; } } if (foundLane != null) { break; } } } return foundLane; }
public static void writeLanes(Process process, XMLStreamWriter xtw) throws Exception { if (!process.getLanes().isEmpty()) { xtw.writeStartElement(ELEMENT_LANESET); xtw.writeAttribute(ATTRIBUTE_ID, "laneSet_" + process.getId()); for (Lane lane : process.getLanes()) { xtw.writeStartElement(ELEMENT_LANE); xtw.writeAttribute(ATTRIBUTE_ID, lane.getId()); if (StringUtils.isNotEmpty(lane.getName())) { xtw.writeAttribute(ATTRIBUTE_NAME, lane.getName()); } boolean didWriteExtensionStartElement = BpmnXMLUtil.writeExtensionElements(lane, false, xtw); if (didWriteExtensionStartElement) { xtw.writeEndElement(); } for (String flowNodeRef : lane.getFlowReferences()) { xtw.writeStartElement(ELEMENT_FLOWNODE_REF); xtw.writeCharacters(flowNodeRef); xtw.writeEndElement(); } xtw.writeEndElement(); } xtw.writeEndElement(); } } }
public void parse(XMLStreamReader xtr, Process activeProcess, BpmnModel model) throws Exception { Lane lane = new Lane(); BpmnXMLUtil.addXMLLocation(lane, xtr); lane.setId(xtr.getAttributeValue(null, ATTRIBUTE_ID)); lane.setName(xtr.getAttributeValue(null, ATTRIBUTE_NAME)); lane.setParentProcess(activeProcess); activeProcess.getLanes().add(lane); BpmnXMLUtil.parseChildElements(ELEMENT_LANE, lane, xtr, model); } }
if (process.getFlowElements().isEmpty() && process.getLanes().isEmpty()) {
fillGraphicInfo(poolNode, poolInfo, true); org.flowable.bpmn.model.Process process = pojoModel.getProcess(pool.getId()); if (process != null && CollectionUtils.isNotEmpty(process.getLanes())) { ArrayNode laneArray = objectMapper.createArrayNode(); for (Lane lane : process.getLanes()) { ObjectNode laneNode = objectMapper.createObjectNode(); laneNode.put("id", lane.getId());
if (process != null) { Map<String, ArrayNode> laneMap = new HashMap<>(); for (Lane lane : process.getLanes()) { GraphicInfo laneGraphicInfo = model.getGraphicInfo(lane.getId()); if (laneGraphicInfo == null) for (Lane lane : process.getLanes()) { if (lane.getFlowReferences().contains(lookForElement.getId())) { laneGraphicInfo = model.getGraphicInfo(lane.getId());
fillGraphicInfo(poolNode, poolInfo, true); org.flowable.bpmn.model.Process process = pojoModel.getProcess(pool.getId()); if (process != null && CollectionUtils.isNotEmpty(process.getLanes())) { ArrayNode laneArray = objectMapper.createArrayNode(); for (Lane lane : process.getLanes()) { ObjectNode laneNode = objectMapper.createObjectNode(); laneNode.put("id", lane.getId());
lane.setName(JsonConverterUtil.getPropertyValueAsString(PROPERTY_NAME, laneNode)); lane.setParentProcess(process); process.getLanes().add(lane);