protected ExecutableScript parseScriptSource(String source, String language, CmmnHandlerContext context) {
if (StringUtil.isExpression(source) && !JuelScriptEngineFactory.names.contains(language)) {
ExpressionManager expressionManager = context.getExpressionManager();
Expression scriptExpression = expressionManager.createExpression(source.trim());
return new DynamicSourceExecutableScript(scriptExpression, language);
}
else {
return parseScript(source, language);
}
}