Class ServiceActivatorFactoryBean
java.lang.Object
org.springframework.integration.config.AbstractSimpleMessageHandlerFactoryBean<MessageHandler>
org.springframework.integration.config.AbstractStandardMessageHandlerFactoryBean
org.springframework.integration.config.ServiceActivatorFactoryBean
- All Implemented Interfaces:
Aware
,BeanFactoryAware
,BeanNameAware
,DisposableBean
,FactoryBean<MessageHandler>
,ApplicationContextAware
,ApplicationEventPublisherAware
FactoryBean for creating
ServiceActivatingHandler
instances.- Since:
- 2.0
- Author:
- Mark Fisher, Gary Russell, David Liu, Artem Bilan
-
Field Summary
Fields inherited from class org.springframework.integration.config.AbstractSimpleMessageHandlerFactoryBean
logger
Fields inherited from interface org.springframework.beans.factory.FactoryBean
OBJECT_TYPE_ATTRIBUTE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
Always returns true - anyAbstractMessageProducingHandler
can be used directly.protected MessageHandler
configureHandler
(ServiceActivatingHandler handler) protected MessageHandler
createDirectHandlerIfPossible
(Object targetObject, String targetMethodName) If the target object is aMessageHandler
and the method is 'handleMessage', return anAbstractMessageProducingHandler
that wraps it.protected MessageHandler
createExpressionEvaluatingHandler
(Expression expression) protected <T> MessageHandler
createMessageProcessingHandler
(MessageProcessor<T> processor) protected MessageHandler
createMethodInvokingHandler
(Object targetObject, String targetMethodName) Subclasses must implement this method to create the MessageHandler.protected void
void
setNotPropagatedHeaders
(String... headers) Methods inherited from class org.springframework.integration.config.AbstractStandardMessageHandlerFactoryBean
checkForIllegalTarget, createDefaultHandler, createHandler, destroy, getSendTimeout, methodIsHandleMessageOrEmpty, setExpression, setExpressionString, setRequiresReply, setSendTimeout, setTargetMethodName, setTargetObject
Methods inherited from class org.springframework.integration.config.AbstractSimpleMessageHandlerFactoryBean
createHandlerInternal, getBeanFactory, getObject, getObjectType, getPreCreationHandlerType, isSingleton, setAdviceChain, setApplicationContext, setApplicationEventPublisher, setAsync, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setOrder, setOutputChannel, setOutputChannelName
-
Constructor Details
-
ServiceActivatorFactoryBean
public ServiceActivatorFactoryBean()
-
-
Method Details
-
setNotPropagatedHeaders
-
createMethodInvokingHandler
Description copied from class:AbstractStandardMessageHandlerFactoryBean
Subclasses must implement this method to create the MessageHandler.- Specified by:
createMethodInvokingHandler
in classAbstractStandardMessageHandlerFactoryBean
- Parameters:
targetObject
- the object to use for method invocation.targetMethodName
- the method name of the target object to invoke.- Returns:
- the method invoking
MessageHandler
implementation.
-
createDirectHandlerIfPossible
protected MessageHandler createDirectHandlerIfPossible(Object targetObject, String targetMethodName) If the target object is aMessageHandler
and the method is 'handleMessage', return anAbstractMessageProducingHandler
that wraps it.- Parameters:
targetObject
- the object to check for Direct Handler requirements.targetMethodName
- the method name to check for Direct Handler requirements.- Returns:
- the
targetObject
as a DirectMessageHandler
ornull
.
-
createExpressionEvaluatingHandler
- Overrides:
createExpressionEvaluatingHandler
in classAbstractStandardMessageHandlerFactoryBean
-
createMessageProcessingHandler
- Overrides:
createMessageProcessingHandler
in classAbstractStandardMessageHandlerFactoryBean
-
configureHandler
-
canBeUsedDirect
Always returns true - anyAbstractMessageProducingHandler
can be used directly.- Overrides:
canBeUsedDirect
in classAbstractStandardMessageHandlerFactoryBean
-
postProcessReplyProducer
- Overrides:
postProcessReplyProducer
in classAbstractStandardMessageHandlerFactoryBean
-