Class DefaultMessageStream
Represents the default IMessageStream implementation.
Namespace: PushTechnology.ClientInterface.Client.Features
Assembly: Diffusion.Client.dll
Syntax
public class DefaultMessageStream : DefaultStream, IMessageStream, IStream, ICallback
Remarks
Deprecated: One-way messaging is deprecated in favor of request-response messaging. See SendRequestAsync<TRequest, TResponse>(String, TRequest). This class will be removed in a future release.
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.
Methods
OnMessageReceived(String, IContent, IReceiveContext)
Called if a message has been received for a specific path.
Declaration
public virtual void OnMessageReceived(string topicPath, IContent content, IReceiveContext context)
Parameters
Type | Name | Description |
---|---|---|
String | topicPath | The path to which the message was sent |
IContent | content | The message content. If the content is known to be of a certain IDataType then ReadValue(IBytes) may be used to convert it. |
IReceiveContext | context | The receive context. |
Remarks
How this originates and what the content contains is dependent on the sender of the message.