@Test public void addChildElement() { SubProcess process = (SubProcess) propertyWriter.getElement(); when(process.getFlowElements()).thenReturn(ECollections.newBasicEList()); BoundaryEventPropertyWriter boundaryEventPropertyWriter = new BoundaryEventPropertyWriter(bpmn2.createBoundaryEvent(), variableScope, new HashSet<>()); UserTaskPropertyWriter userTaskPropertyWriter = new UserTaskPropertyWriter(bpmn2.createUserTask(), variableScope, new HashSet<>()); propertyWriter.addChildElement(boundaryEventPropertyWriter); propertyWriter.addChildElement(userTaskPropertyWriter); assertThat(process.getFlowElements().get(0)).isEqualTo(userTaskPropertyWriter.getFlowElement()); assertThat(process.getFlowElements().get(1)).isEqualTo(boundaryEventPropertyWriter.getFlowElement()); }
public void addChildElement(BasePropertyWriter p) { p.setParent(this); Processes.addChildElement( p, childElements, process, simulationParameters, itemDefinitions, rootElements); }
SubProcessPropertyWriter extends MultipleInstanceActivityPropertyWriter implements ElementContainer { public void addChildElement(BasePropertyWriter p) { p.setParent(this); Processes.addChildElement( p, childElements, process, simulationParameters, itemDefinitions, rootElements); } }
SubProcessPropertyWriter extends MultipleInstanceActivityPropertyWriter implements ElementContainer { public void addChildElement(BasePropertyWriter p) { p.setParent(this); Processes.addChildElement( p, childElements, process, simulationParameters, itemDefinitions, rootElements); } SubProcessPropertyWriter(SubProcess process, VariableScope variableScope, Set<DataObject> dataObjects); }
SubProcessPropertyWriter extends MultipleInstanceActivityPropertyWriter implements ElementContainer { public void addChildElement(BasePropertyWriter p) { p.setParent(this); Processes.addChildElement( p, childElements, process, simulationParameters, itemDefinitions, rootElements); } SubProcessPropertyWriter(SubProcess process, VariableScope variableScope, Set<DataObject> dataObjects); void addChildElement(BasePropertyWriter p); @Override Collection<BasePropertyWriter> getChildElements(); BasePropertyWriter getChildElement(String id); @Override void addChildEdge(BPMNEdge edge); void setDescription(String value); void setSimulationSet(SimulationSet simulations); void setProcessVariables(BaseProcessVariables processVariables); void addLaneSet(Collection<LanePropertyWriter> lanes); void setOnEntryAction(OnEntryAction onEntryAction); void setOnExitAction(OnExitAction onExitAction); void setAsync(Boolean isAsync); void setSlaDueDate(SLADueDate slaDueDate); @Override void setAbsoluteBounds(Node<? extends View, ?> node); }
SubProcessPropertyWriter extends MultipleInstanceActivityPropertyWriter implements ElementContainer { public void addChildElement(BasePropertyWriter p) { p.setParent(this); Processes.addChildElement( p, childElements, process, simulationParameters, itemDefinitions, rootElements); } SubProcessPropertyWriter(SubProcess process, VariableScope variableScope, Set<DataObject> dataObjects); void addChildElement(BasePropertyWriter p); @Override Collection<BasePropertyWriter> getChildElements(); BasePropertyWriter getChildElement(String id); @Override void addChildEdge(BPMNEdge edge); void setDescription(String value); void setSimulationSet(SimulationSet simulations); void setProcessVariables(BaseProcessVariables processVariables); void addLaneSet(Collection<LanePropertyWriter> lanes); void setOnEntryAction(OnEntryAction onEntryAction); void setOnExitAction(OnExitAction onExitAction); void setAsync(Boolean isAsync); void setSlaDueDate(SLADueDate slaDueDate); @Override void setAbsoluteBounds(Node<? extends View, ?> node);  }