public class Message extends Packet
Constructor and Description |
---|
Message(java.lang.String to,
java.lang.String from,
java.io.Serializable value)
An message to a destination with a source address.
|
Modifier and Type | Method and Description |
---|---|
void |
dispatch(MessageStream handler,
MessageStream toSource)
SPI method to dispatch the packet to the proper handler
|
java.io.Serializable |
getValue()
Returns the message value
|
java.lang.String |
toString() |
dispatchError, getFrom, getTo
public Message(java.lang.String to, java.lang.String from, java.io.Serializable value)
to
- the target addressfrom
- the source addressvalue
- the message contentpublic java.io.Serializable getValue()
public void dispatch(MessageStream handler, MessageStream toSource)