public class MethodInvokingMessageProcessor<T> extends AbstractMessageProcessor<T> implements ManageableLifecycle
EXPRESSION_PARSER, logger
Constructor and Description |
---|
MethodInvokingMessageProcessor(Object targetObject,
Class<? extends Annotation> annotationType) |
MethodInvokingMessageProcessor(Object targetObject,
Method method) |
MethodInvokingMessageProcessor(Object targetObject,
String methodName) |
MethodInvokingMessageProcessor(Object targetObject,
String methodName,
boolean canProcessMessageList) |
Modifier and Type | Method and Description |
---|---|
boolean |
isRunning() |
T |
processMessage(Message<?> message)
Process the Message and return a value (or null).
|
void |
setBeanFactory(BeanFactory beanFactory)
Specify a BeanFactory in order to enable resolution via
@beanName in the expression. |
void |
setConversionService(ConversionService conversionService) |
void |
setUseSpelInvoker(boolean useSpelInvoker)
A
boolean flag to use SpEL Expression evaluation or
InvocableHandlerMethod
for target method invocation. |
void |
start() |
void |
stop() |
afterPropertiesSet, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, getBeanFactory, getEvaluationContext, getEvaluationContext, getMessageBuilderFactory, onInit
public MethodInvokingMessageProcessor(Object targetObject, Method method)
public MethodInvokingMessageProcessor(Object targetObject, String methodName)
public MethodInvokingMessageProcessor(Object targetObject, String methodName, boolean canProcessMessageList)
public MethodInvokingMessageProcessor(Object targetObject, Class<? extends Annotation> annotationType)
public void setConversionService(ConversionService conversionService)
setConversionService
in class AbstractExpressionEvaluator
public void setBeanFactory(BeanFactory beanFactory)
AbstractExpressionEvaluator
@beanName
in the expression.setBeanFactory
in interface BeanFactoryAware
setBeanFactory
in class AbstractExpressionEvaluator
public void setUseSpelInvoker(boolean useSpelInvoker)
boolean
flag to use SpEL Expression evaluation or
InvocableHandlerMethod
for target method invocation.useSpelInvoker
- to use SpEL Expression evaluation or not.public void start()
start
in interface Lifecycle
start
in interface ManageableLifecycle
public void stop()
stop
in interface Lifecycle
stop
in interface ManageableLifecycle
public boolean isRunning()
isRunning
in interface Lifecycle
isRunning
in interface ManageableLifecycle
@Nullable public T processMessage(Message<?> message)
MessageProcessor
processMessage
in interface MessageProcessor<T>
processMessage
in class AbstractMessageProcessor<T>
message
- The message to process.