Class MethodInvokingMessageListProcessor<T>

java.lang.Object
org.springframework.integration.util.AbstractExpressionEvaluator
org.springframework.integration.aggregator.MethodInvokingMessageListProcessor<T>
Type Parameters:
T - the method evaluation expecetd result type.
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.InitializingBean, org.springframework.context.Lifecycle, ManageableLifecycle

public class MethodInvokingMessageListProcessor<T> extends AbstractExpressionEvaluator implements ManageableLifecycle
A MessageListProcessor implementation that invokes a method on a target POJO.
Since:
2.0
  • Constructor Details

    • MethodInvokingMessageListProcessor

      public MethodInvokingMessageListProcessor(Object targetObject, Method method, Class<T> expectedType)
    • MethodInvokingMessageListProcessor

      public MethodInvokingMessageListProcessor(Object targetObject, Method method)
    • MethodInvokingMessageListProcessor

      public MethodInvokingMessageListProcessor(Object targetObject, String methodName, Class<T> expectedType)
    • MethodInvokingMessageListProcessor

      public MethodInvokingMessageListProcessor(Object targetObject, String methodName)
    • MethodInvokingMessageListProcessor

      public MethodInvokingMessageListProcessor(Object targetObject, Class<? extends Annotation> annotationType)
  • Method Details

    • setBeanFactory

      public void setBeanFactory(@NonNull org.springframework.beans.factory.BeanFactory beanFactory)
      Description copied from class: AbstractExpressionEvaluator
      Specify a BeanFactory in order to enable resolution via @beanName in the expression.
      Specified by:
      setBeanFactory in interface org.springframework.beans.factory.BeanFactoryAware
      Overrides:
      setBeanFactory in class AbstractExpressionEvaluator
    • setUseSpelInvoker

      public void setUseSpelInvoker(boolean useSpelInvoker)
      A boolean flag to use SpEL Expression evaluation or InvocableHandlerMethod for target method invocation.
      Parameters:
      useSpelInvoker - to use SpEL Expression evaluation or not.
      Since:
      5.0
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • process

      public T process(Collection<org.springframework.messaging.Message<?>> messages, Map<String,Object> aggregateHeaders)
    • start

      public void start()
      Specified by:
      start in interface org.springframework.context.Lifecycle
      Specified by:
      start in interface ManageableLifecycle
    • stop

      public void stop()
      Specified by:
      stop in interface org.springframework.context.Lifecycle
      Specified by:
      stop in interface ManageableLifecycle
    • isRunning

      public boolean isRunning()
      Specified by:
      isRunning in interface org.springframework.context.Lifecycle
      Specified by:
      isRunning in interface ManageableLifecycle