Class MethodInvokingCorrelationStrategy
java.lang.Object
org.springframework.integration.aggregator.MethodInvokingCorrelationStrategy
- All Implemented Interfaces:
Aware,BeanFactoryAware,Lifecycle,CorrelationStrategy,ManageableLifecycle
public class MethodInvokingCorrelationStrategy
extends Object
implements CorrelationStrategy, BeanFactoryAware, ManageableLifecycle
CorrelationStrategy implementation that works as an adapter to another bean.- Author:
- Marius Bogoevici, Dave Syer, Artem Bilan, Gary Russell
-
Constructor Summary
ConstructorsConstructorDescriptionMethodInvokingCorrelationStrategy(Object object, Method method) MethodInvokingCorrelationStrategy(Object object, String methodName) -
Method Summary
Modifier and TypeMethodDescriptiongetCorrelationKey(Message<?> message) Find the correlation key for the given message.booleanvoidsetBeanFactory(BeanFactory beanFactory) voidstart()voidstop()
-
Constructor Details
-
MethodInvokingCorrelationStrategy
-
MethodInvokingCorrelationStrategy
-
-
Method Details
-
setBeanFactory
- Specified by:
setBeanFactoryin interfaceBeanFactoryAware- Throws:
BeansException
-
getCorrelationKey
Description copied from interface:CorrelationStrategyFind the correlation key for the given message. If no key can be determined the strategy should not returnnull, but throw an exception.- Specified by:
getCorrelationKeyin interfaceCorrelationStrategy- Parameters:
message- The message.- Returns:
- The correlation key.
-
start
public void start()- Specified by:
startin interfaceLifecycle- Specified by:
startin interfaceManageableLifecycle
-
stop
public void stop()- Specified by:
stopin interfaceLifecycle- Specified by:
stopin interfaceManageableLifecycle
-
isRunning
public boolean isRunning()- Specified by:
isRunningin interfaceLifecycle- Specified by:
isRunningin interfaceManageableLifecycle
-