use of org.camunda.bpm.engine.impl.dmn.el.ProcessEngineElProvider in project camunda-bpm-platform by camunda.
the class DmnEngineConfigurationBuilder method build.
/**
* Modify the given DMN engine configuration and return it.
*/
public DefaultDmnEngineConfiguration build() {
List<DmnDecisionEvaluationListener> decisionEvaluationListeners = createCustomPostDecisionEvaluationListeners();
dmnEngineConfiguration.setCustomPostDecisionEvaluationListeners(decisionEvaluationListeners);
// override the decision table handler
DmnTransformer dmnTransformer = dmnEngineConfiguration.getTransformer();
dmnTransformer.getElementTransformHandlerRegistry().addHandler(Definitions.class, new DecisionRequirementsDefinitionTransformHandler());
dmnTransformer.getElementTransformHandlerRegistry().addHandler(Decision.class, new DecisionDefinitionHandler());
// do not override the script engine resolver if set
if (dmnEngineConfiguration.getScriptEngineResolver() == null) {
ensureNotNull("scriptEngineResolver", scriptEngineResolver);
dmnEngineConfiguration.setScriptEngineResolver(scriptEngineResolver);
}
// do not override the el provider if set
if (dmnEngineConfiguration.getElProvider() == null) {
ensureNotNull("expressionManager", expressionManager);
ProcessEngineElProvider elProvider = new ProcessEngineElProvider(expressionManager);
dmnEngineConfiguration.setElProvider(elProvider);
}
return dmnEngineConfiguration;
}
Aggregations