public class MethodRabbitListenerEndpoint extends AbstractRabbitListenerEndpoint
RabbitListenerEndpoint
providing the method to invoke to process
an incoming message for this endpoint.Constructor and Description |
---|
MethodRabbitListenerEndpoint() |
Modifier and Type | Method and Description |
---|---|
protected HandlerAdapter |
configureListenerAdapter(MessagingMessageListenerAdapter messageListener)
Create a
HandlerAdapter for this listener adapter. |
protected MessagingMessageListenerAdapter |
createMessageListener(MessageListenerContainer container)
Create a
MessageListener that is able to serve this endpoint for the
specified container. |
protected MessagingMessageListenerAdapter |
createMessageListenerInstance()
Create an empty
MessagingMessageListenerAdapter instance. |
Object |
getBean() |
protected StringBuilder |
getEndpointDescription() |
protected MessageHandlerMethodFactory |
getMessageHandlerMethodFactory() |
Method |
getMethod() |
void |
setBean(Object bean)
Set the object instance that should manage this endpoint.
|
void |
setMessageHandlerMethodFactory(MessageHandlerMethodFactory messageHandlerMethodFactory)
Set the
MessageHandlerMethodFactory to use to build the
InvocableHandlerMethod responsible to manage the invocation
of this endpoint. |
void |
setMethod(Method method)
Set the method to invoke to process a message managed by this endpoint.
|
getAdmin, getBeanExpressionContext, getBeanFactory, getBeanResolver, getGroup, getId, getPriority, getQueueNames, getQueues, getResolver, isExclusive, setAdmin, setBeanFactory, setExclusive, setGroup, setId, setPriority, setQueueNames, setQueues, setupListenerContainer, toString
public void setBean(Object bean)
bean
- the target bean instance.public Object getBean()
public void setMethod(Method method)
method
- the target method for the bean
.public Method getMethod()
public void setMessageHandlerMethodFactory(MessageHandlerMethodFactory messageHandlerMethodFactory)
MessageHandlerMethodFactory
to use to build the
InvocableHandlerMethod
responsible to manage the invocation
of this endpoint.messageHandlerMethodFactory
- the MessageHandlerMethodFactory
instance.protected MessageHandlerMethodFactory getMessageHandlerMethodFactory()
protected MessagingMessageListenerAdapter createMessageListener(MessageListenerContainer container)
AbstractRabbitListenerEndpoint
MessageListener
that is able to serve this endpoint for the
specified container.createMessageListener
in class AbstractRabbitListenerEndpoint
container
- the MessageListenerContainer
to create a MessageListener
.MessageListener
instance.protected HandlerAdapter configureListenerAdapter(MessagingMessageListenerAdapter messageListener)
HandlerAdapter
for this listener adapter.messageListener
- the listener adapter.protected MessagingMessageListenerAdapter createMessageListenerInstance()
MessagingMessageListenerAdapter
instance.MessagingMessageListenerAdapter
instance.protected StringBuilder getEndpointDescription()
getEndpointDescription
in class AbstractRabbitListenerEndpoint
Available to subclasses, for inclusion in their toString()
result.