public abstract class AbstractExpressionEvaluator extends Object implements BeanFactoryAware, InitializingBean
Modifier and Type | Field and Description |
---|---|
protected static ExpressionParser |
EXPRESSION_PARSER |
protected LogAccessor |
logger |
Constructor and Description |
---|
AbstractExpressionEvaluator() |
Modifier and Type | Method and Description |
---|---|
void |
afterPropertiesSet() |
protected Object |
evaluateExpression(Expression expression) |
protected <T> T |
evaluateExpression(Expression expression,
Class<T> expectedType) |
protected <T> T |
evaluateExpression(Expression expression,
Message<?> message,
Class<T> expectedType) |
protected Object |
evaluateExpression(Expression expression,
Object input) |
protected <T> T |
evaluateExpression(Expression expression,
Object input,
Class<T> expectedType) |
protected Object |
evaluateExpression(String expression,
Object input) |
protected <T> T |
evaluateExpression(String expression,
Object input,
Class<T> expectedType) |
protected BeanFactory |
getBeanFactory() |
protected StandardEvaluationContext |
getEvaluationContext() |
protected StandardEvaluationContext |
getEvaluationContext(boolean beanFactoryRequired)
Emits a WARN log if the beanFactory field is null, unless the argument is false.
|
protected MessageBuilderFactory |
getMessageBuilderFactory() |
protected void |
onInit() |
void |
setBeanFactory(BeanFactory beanFactory)
Specify a BeanFactory in order to enable resolution via
@beanName in the expression. |
void |
setConversionService(ConversionService conversionService) |
protected final LogAccessor logger
protected static final ExpressionParser EXPRESSION_PARSER
public void setBeanFactory(BeanFactory beanFactory)
@beanName
in the expression.setBeanFactory
in interface BeanFactoryAware
protected BeanFactory getBeanFactory()
public void setConversionService(ConversionService conversionService)
protected MessageBuilderFactory getMessageBuilderFactory()
public final void afterPropertiesSet()
afterPropertiesSet
in interface InitializingBean
protected StandardEvaluationContext getEvaluationContext()
protected final StandardEvaluationContext getEvaluationContext(boolean beanFactoryRequired)
beanFactoryRequired
- set to false to suppress the warning.@Nullable protected <T> T evaluateExpression(Expression expression, Message<?> message, @Nullable Class<T> expectedType)
@Nullable protected <T> T evaluateExpression(String expression, Object input, @Nullable Class<T> expectedType)
@Nullable protected Object evaluateExpression(Expression expression, Object input)
@Nullable protected <T> T evaluateExpression(Expression expression, @Nullable Class<T> expectedType)
@Nullable protected Object evaluateExpression(Expression expression)
@Nullable protected <T> T evaluateExpression(Expression expression, Object input, @Nullable Class<T> expectedType)
protected void onInit()