public class MVELExpressionExecutor extends Object implements ExpressionExecutor<MVELExpressionLanguageContext>
ReflectiveAccessorOptimizer
implementation rather than the default
DynamicOptimizer
(which generates byte-code accessors using ASM) because we found that, at least
with JDK7, the ReflectiveAccessorOptimizer
was fastest in typical Mule use cases.Modifier and Type | Field and Description |
---|---|
protected static int |
COMPILED_EXPRESSION_MAX_CACHE_SIZE |
protected com.google.common.cache.LoadingCache<String,Serializable> |
compiledExpressionsCache |
protected static String |
DISABLE_MEL_EXPRESSION_CACHE |
protected org.mule.mvel2.ParserConfiguration |
parserConfiguration |
Constructor and Description |
---|
MVELExpressionExecutor(org.mule.mvel2.ParserConfiguration parserConfiguration) |
Modifier and Type | Method and Description |
---|---|
Object |
execute(String expression,
MVELExpressionLanguageContext context)
Execute an expression using using the provided context.
|
Serializable |
getCompiledExpression(String expression)
Compile an expression.
|
void |
validate(String expression)
Validate the expression
|
protected static final String DISABLE_MEL_EXPRESSION_CACHE
protected static final int COMPILED_EXPRESSION_MAX_CACHE_SIZE
protected org.mule.mvel2.ParserConfiguration parserConfiguration
protected com.google.common.cache.LoadingCache<String,Serializable> compiledExpressionsCache
public MVELExpressionExecutor(org.mule.mvel2.ParserConfiguration parserConfiguration)
public Object execute(String expression, MVELExpressionLanguageContext context)
ExpressionExecutor
execute
in interface ExpressionExecutor<MVELExpressionLanguageContext>
public void validate(String expression) throws InvalidExpressionException
ExpressionExecutor
validate
in interface ExpressionExecutor<MVELExpressionLanguageContext>
InvalidExpressionException
public Serializable getCompiledExpression(String expression)
expression
- Expression to be compiledSerializable
object representing the compiled expressionCopyright © 2003–2016 MuleSoft, Inc.. All rights reserved.