Package net.engio.mbassy.dispatch
Class EnvelopedMessageDispatcher
- java.lang.Object
-
- net.engio.mbassy.subscription.AbstractSubscriptionContextAware
-
- net.engio.mbassy.dispatch.DelegatingMessageDispatcher
-
- net.engio.mbassy.dispatch.EnvelopedMessageDispatcher
-
- All Implemented Interfaces:
IMessageDispatcher
,ISubscriptionContextAware
public class EnvelopedMessageDispatcher extends DelegatingMessageDispatcher
The enveloped dispatcher will wrap published messages in an envelope before passing them to their configured dispatcher. All enveloped message handlers will have this dispatcher in their chain
-
-
Constructor Summary
Constructors Constructor Description EnvelopedMessageDispatcher(IMessageDispatcher dispatcher)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
dispatch(MessagePublication publication, java.lang.Object message, java.lang.Iterable listeners)
Delivers the given message to the given set of listeners.-
Methods inherited from class net.engio.mbassy.dispatch.DelegatingMessageDispatcher
getDelegate, getInvocation
-
Methods inherited from class net.engio.mbassy.subscription.AbstractSubscriptionContextAware
getContext
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.engio.mbassy.subscription.ISubscriptionContextAware
getContext
-
-
-
-
Constructor Detail
-
EnvelopedMessageDispatcher
public EnvelopedMessageDispatcher(IMessageDispatcher dispatcher)
-
-
Method Detail
-
dispatch
public void dispatch(MessagePublication publication, java.lang.Object message, java.lang.Iterable listeners)
Description copied from interface:IMessageDispatcher
Delivers the given message to the given set of listeners. Delivery may be delayed, aborted or restricted in various ways, depending on the configuration of the dispatcher- Parameters:
publication
- The message publication that initiated the dispatchmessage
- The message that should be delivered to the listenerslisteners
- The listeners that should receive the message
-
-