|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.integration.dispatcher.AbstractDispatcher
public abstract class AbstractDispatcher
Base class for MessageDispatcher
implementations.
Field Summary | |
---|---|
protected org.apache.commons.logging.Log |
logger
|
private MessageExchangeTemplate |
messageExchangeTemplate
|
protected java.util.Set<MessageTarget> |
targets
|
private org.springframework.core.task.TaskExecutor |
taskExecutor
|
Constructor Summary | |
---|---|
AbstractDispatcher()
|
Method Summary | |
---|---|
protected org.springframework.core.task.TaskExecutor |
getTaskExecutor()
|
protected boolean |
sendMessageToTarget(Message<?> message,
MessageTarget target)
A convenience method for subclasses to send a Message to a single target. |
void |
setSendTimeout(long sendTimeout)
Specify the timeout for sending to a target (in milliseconds). |
void |
setTaskExecutor(org.springframework.core.task.TaskExecutor taskExecutor)
Specify a TaskExecutor for invoking the target endpoints. |
boolean |
subscribe(MessageTarget target)
Register a MessageTarget as a subscriber to this source. |
boolean |
unsubscribe(MessageTarget target)
Remove a MessageTarget from the subscribers of this source. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.springframework.integration.dispatcher.MessageDispatcher |
---|
send |
Field Detail |
---|
protected final org.apache.commons.logging.Log logger
protected final java.util.Set<MessageTarget> targets
private volatile org.springframework.core.task.TaskExecutor taskExecutor
private final MessageExchangeTemplate messageExchangeTemplate
Constructor Detail |
---|
public AbstractDispatcher()
Method Detail |
---|
public void setSendTimeout(long sendTimeout)
MessageDispatcher
setSendTimeout
in interface MessageDispatcher
public boolean subscribe(MessageTarget target)
SubscribableSource
MessageTarget
as a subscriber to this source.
subscribe
in interface MessageDispatcher
subscribe
in interface SubscribableSource
public boolean unsubscribe(MessageTarget target)
SubscribableSource
MessageTarget
from the subscribers of this source.
unsubscribe
in interface MessageDispatcher
unsubscribe
in interface SubscribableSource
public void setTaskExecutor(org.springframework.core.task.TaskExecutor taskExecutor)
TaskExecutor
for invoking the target endpoints.
If none is provided, the invocation will occur in the thread
that runs this polling dispatcher.
protected org.springframework.core.task.TaskExecutor getTaskExecutor()
protected final boolean sendMessageToTarget(Message<?> message, MessageTarget target)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |