@Override default T exclusiveGate(String defaultFlow) { return add(new ExclusiveGateway(nextStepId(), defaultFlow)); }
@Override public String toString() { return "ExclusiveGateway (" + getId() + ") {" + "defaultFlow='" + defaultFlow + '\'' + '}'; } }
ExclusiveGateway gw = new ExclusiveGateway(idGenerator.nextId()); List<AbstractElement> elements = new ArrayList<>(); SequenceFlow f = new SequenceFlow(idGenerator.nextId(), gw.getId(), toId, (String) expr); elements.add(f); elements.addAll(es);
@Override public List<Action> handle(ProcessInstance state, ProcessElementCommand cmd, List<Action> actions) throws ExecutionException { actions.add(new PopCommandAction()); IndexedProcessDefinition pd = state.getDefinition(cmd.getDefinitionId()); ExclusiveGateway gw = (ExclusiveGateway) ProcessDefinitionUtils.findElement(pd, cmd.getElementId()); actions.add(new EvaluateAndFollowFlowsAction(cmd.getDefinitionId(), cmd.getElementId(), gw.getDefaultFlow())); return actions; } }
@Override default T exclusiveGate() { return add(new ExclusiveGateway(nextStepId())); }
ExclusiveGateway eg = new ExclusiveGateway(id, attributes.getValue("default")); children.add(eg); break;
result.addElement(new ServiceTask(nextItemTaskId, ExpressionType.SIMPLE, "${__withItemsUtils.nextItem(execution)}", Collections.singleton(taskVars), null, true)); result.addElement(new ServiceTask(processOutVarsTask, ExpressionType.SIMPLE, "${__withItemsUtils.processOutVars(execution, __0)}", Collections.singleton(outVarsMapping), null, true)); result.addElement(new ExclusiveGateway(hasNextGwId)); result.addElement(new ServiceTask(cleanupTaskId, ExpressionType.SIMPLE, "${__withItemsUtils.cleanup(execution, __0)}", Collections.singleton(outVarsMapping), null, true));
@Override public Chunk convert(ConverterContext ctx, YamlIfExpr s) throws YamlConverterException { Chunk c = new Chunk(); String gwId = ctx.nextId(); c.addElement(new ExclusiveGateway(gwId)); c.addSourceMap(gwId, toSourceMap(s, "Check: " + s.getExpr())); // "then" branch Chunk thenChunk = ctx.convert(s.getThenSteps()); // connect "then" steps with the gateway String thenDst = thenChunk.firstElement().getId(); c.addElement(new SequenceFlow(ctx.nextId(), gwId, thenDst, s.getExpr())); c.addElements(thenChunk.getElements()); c.addOutputs(thenChunk.getOutputs()); c.addSourceMaps(thenChunk.getSourceMap()); // "else" branch applyElseBlock(ctx, c, gwId, s.getElseSteps()); return c; }
c.addElement(new ExclusiveGateway(gwId)); c.addElement(new SequenceFlow(ctx.nextId(), id, gwId)); c.addSourceMap(gwId, toSourceMap(s, "Switch: " + s.getExpr()));
c.addElement(new ExclusiveGateway(retryCountGwId));