use of org.camunda.bpm.dmn.engine.impl.delegate.DmnDecisionEvaluationEventImpl in project camunda-engine-dmn by camunda.
the class DefaultDmnDecisionContext method generateDecisionEvaluationEvent.
protected void generateDecisionEvaluationEvent(List<DmnDecisionLogicEvaluationEvent> evaluatedEvents) {
DmnDecisionLogicEvaluationEvent rootEvaluatedEvent = null;
DmnDecisionEvaluationEventImpl decisionEvaluationEvent = new DmnDecisionEvaluationEventImpl();
long executedDecisionElements = 0L;
for (DmnDecisionLogicEvaluationEvent evaluatedEvent : evaluatedEvents) {
executedDecisionElements += evaluatedEvent.getExecutedDecisionElements();
rootEvaluatedEvent = evaluatedEvent;
}
decisionEvaluationEvent.setDecisionResult(rootEvaluatedEvent);
decisionEvaluationEvent.setExecutedDecisionElements(executedDecisionElements);
evaluatedEvents.remove(rootEvaluatedEvent);
decisionEvaluationEvent.setRequiredDecisionResults(evaluatedEvents);
for (DmnDecisionEvaluationListener evaluationListener : evaluationListeners) {
evaluationListener.notify(decisionEvaluationEvent);
}
}
Aggregations