Exemplo n.º 1
0
        protected internal override void ExecuteParse(BpmnParse bpmnParse, Transaction transaction)
        {
            transaction.Behavior = bpmnParse.ActivityBehaviorFactory.CreateTransactionActivityBehavior(transaction);

            bpmnParse.ProcessFlowElements(transaction.FlowElements);
            ProcessArtifacts(bpmnParse, transaction.Artifacts);
        }
Exemplo n.º 2
0
        protected internal virtual IProcessDefinitionEntity TransformProcess(BpmnParse bpmnParse, Process process)
        {
            IProcessDefinitionEntity currentProcessDefinition = Context.CommandContext.ProcessDefinitionEntityManager.Create();

            bpmnParse.CurrentProcessDefinition = currentProcessDefinition;

            /*
             * Mapping object model - bpmn xml: processDefinition.id -> generated by activiti engine processDefinition.key -> bpmn id (required) processDefinition.name -> bpmn name (optional)
             */
            currentProcessDefinition.Key          = process.Id;
            currentProcessDefinition.Name         = process.Name;
            currentProcessDefinition.Category     = bpmnParse.BpmnModel.TargetNamespace;
            currentProcessDefinition.Description  = process.Documentation;
            currentProcessDefinition.DeploymentId = bpmnParse.Deployment.Id;

            if (bpmnParse.Deployment.EngineVersion is object)
            {
                currentProcessDefinition.EngineVersion = bpmnParse.Deployment.EngineVersion;
            }

            CreateEventListeners(bpmnParse, process.EventListeners);

            if (logger.IsEnabled(LogLevel.Debug))
            {
                logger.LogDebug($"Parsing process {currentProcessDefinition.Key}");
            }

            bpmnParse.ProcessFlowElements(process.FlowElements);
            ProcessArtifacts(bpmnParse, process.Artifacts);

            return(currentProcessDefinition);
        }
Exemplo n.º 3
0
        protected internal override void ExecuteParse(BpmnParse bpmnParse, SubProcess subProcess)
        {
            subProcess.Behavior = bpmnParse.ActivityBehaviorFactory.CreateAdhocSubprocessActivityBehavior(subProcess);

            bpmnParse.ProcessFlowElements(subProcess.FlowElements);
            ProcessArtifacts(bpmnParse, subProcess.Artifacts);
        }
Exemplo n.º 4
0
        protected internal override void ExecuteParse(BpmnParse bpmnParse, SubProcess subProcess)
        {
            subProcess.Behavior = bpmnParse.ActivityBehaviorFactory.CreateSubprocessActivityBehavior(subProcess);

            bpmnParse.ProcessFlowElements(subProcess.FlowElements);
            ProcessArtifacts(bpmnParse, subProcess.Artifacts);

            // no data objects for event subprocesses

            /*
             * if (!(subProcess instanceof EventSubProcess)) { // parse out any data objects from the template in order to set up the necessary process variables Map<String, Object> variables =
             * processDataObjects(bpmnParse, subProcess.getDataObjects(), activity); activity.setVariables(variables); }
             *
             * bpmnParse.removeCurrentScope(); bpmnParse.removeCurrentSubProcess();
             *
             * if (subProcess.getIoSpecification() != null) { IOSpecification ioSpecification = createIOSpecification(bpmnParse, subProcess.getIoSpecification()); activity.setIoSpecification(ioSpecification);
             * }
             */
        }