public abstract class AbstractReplyProducingMessageHandler extends AbstractMessageProducingHandler implements org.springframework.beans.factory.BeanClassLoaderAware
Modifier and Type | Class and Description |
---|---|
static interface |
AbstractReplyProducingMessageHandler.RequestHandler |
messagingTemplate
logger
Constructor and Description |
---|
AbstractReplyProducingMessageHandler() |
Modifier and Type | Method and Description |
---|---|
protected void |
doInit() |
protected java.lang.Object |
doInvokeAdvisedRequestHandler(org.springframework.messaging.Message<?> message) |
protected void |
handleMessageInternal(org.springframework.messaging.Message<?> message) |
protected abstract java.lang.Object |
handleRequestMessage(org.springframework.messaging.Message<?> requestMessage)
Subclasses must implement this method to handle the request Message.
|
protected boolean |
hasAdviceChain() |
protected void |
onInit()
Subclasses may implement this for initialization logic.
|
protected void |
produceReply(java.lang.Object reply,
org.springframework.messaging.MessageHeaders requestHeaders) |
void |
setAdviceChain(java.util.List<org.aopalliance.aop.Advice> adviceChain) |
void |
setBeanClassLoader(java.lang.ClassLoader beanClassLoader) |
void |
setChannelResolver(org.springframework.messaging.core.DestinationResolver<org.springframework.messaging.MessageChannel> channelResolver)
Set the DestinationResolver<MessageChannel> to be used when there is no default output channel.
|
void |
setRequiresReply(boolean requiresReply)
Flag whether a reply is required.
|
protected boolean |
shouldCopyRequestHeaders()
Subclasses may override this.
|
getOutputChannel, setOutputChannel, setOutputChannelName, setSendTimeout
getComponentType, getOrder, handleMessage, setOrder, setShouldTrack
afterPropertiesSet, getApplicationContext, getApplicationContextId, getBeanFactory, getComponentName, getConversionService, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, setApplicationContext, setBeanFactory, setBeanName, setComponentName, setConversionService, setMessageBuilderFactory, setTaskScheduler, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getComponentName
public AbstractReplyProducingMessageHandler()
public void setRequiresReply(boolean requiresReply)
requiresReply
- true if a reply is required.public void setChannelResolver(org.springframework.messaging.core.DestinationResolver<org.springframework.messaging.MessageChannel> channelResolver)
channelResolver
- The channel resolver.public void setAdviceChain(java.util.List<org.aopalliance.aop.Advice> adviceChain)
protected boolean hasAdviceChain()
public void setBeanClassLoader(java.lang.ClassLoader beanClassLoader)
setBeanClassLoader
in interface org.springframework.beans.factory.BeanClassLoaderAware
protected final void onInit() throws java.lang.Exception
IntegrationObjectSupport
onInit
in class AbstractMessageProducingHandler
java.lang.Exception
- Any exception.protected void doInit()
protected final void handleMessageInternal(org.springframework.messaging.Message<?> message)
handleMessageInternal
in class AbstractMessageHandler
protected java.lang.Object doInvokeAdvisedRequestHandler(org.springframework.messaging.Message<?> message)
protected void produceReply(java.lang.Object reply, org.springframework.messaging.MessageHeaders requestHeaders)
protected boolean shouldCopyRequestHeaders()
protected abstract java.lang.Object handleRequestMessage(org.springframework.messaging.Message<?> requestMessage)
requestMessage
- The request message.null
.