public static class Messaging.MessageStream.Default extends Stream.Default implements Messaging.MessageStream
Messaging.MessageStream
implementation.
This simply logs onMessageReceived calls at 'debug' level which may be useful for debugging purposes. This method should be overridden to provide processing of inbound messages.
Messaging.MessageStream.Default
Constructor and Description |
---|
Messaging.MessageStream.Default() |
Modifier and Type | Method and Description |
---|---|
void |
onMessageReceived(String topicPath,
Content content,
ReceiveContext context)
This indicates a message has been received for a specific path.
|
onClose
onError
public void onMessageReceived(String topicPath, Content content, ReceiveContext context)
Messaging.MessageStream
How this originates and what the content contains is dependent on the sender of the message.
onMessageReceived
in interface Messaging.MessageStream
topicPath
- the path to which the message was sentcontent
- the message content. If the content is known to be of
a certain data type
then
DataType.readValue(Bytes)
may be used to convert it.context
- the receive contextCopyright © 2016 Push Technology Ltd. All Rights Reserved.