Diffusion .NET Classic API - Core and Common  5.9.4
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler Interface Reference

A 'topic notify' topic handler. More...

Inheritance diagram for PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler:
PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.TopicNotifyTopicHandlerImpl

Public Member Functions

void SetNotificationLevel (NotificationLevel level)
 This can be used to change the notification level from that initially specified. More...
 
void SetNotificationDetails (NotificationLevel addLevel, bool notifyRemoval, bool notifyUpdate)
 This can be used to set the notification details required. More...
 
void Select (SelectionMode mode, TopicSet selections)
 Sends a request to the server to update the selection of topics that topic add notifications will be received for. As this is an asynchronous request to the server the update may not take effect immediately. Upon receiving the new selection set the server will check if there are any existing topics that match the selections (that did not match before) and send a separate add notification for each one. New topics that match the selections will be notified as and when they are added. More...
 

Properties

IDiffusionClientConnector Connection [get]
 Returns the client connection. More...
 
NotificationLevel NotificationLevel [get]
 Returns the current add notification level. More...
 
bool IsNotifyingRemoval [get]
 Indicates whether notifying topic removals. More...
 
bool IsNotifyingUpdate [get]
 Indicates whether notifying topic property updates. More...
 

Detailed Description

A 'topic notify' topic handler.

This is an object which is used to send commands to a 'topic notify' topic. The handler simplifies the use of such a topic, and avoids having to format messages to send to the topic or parse messages received from it.

Such a handler is created using ExternalClient.CreateTopicNotifyTopicHandler, and all notifications from the topic will be routed through the supplied listener.

When such a handler is in use, messages received on the topic will not be delivered via normal listener mechanisms but will be parsed and notified to the TopicNotifyTopicListener specified.

When the handler is create the notification level required is specified. This indicates how much detail is required when each topic addition is notified.

After creating the handler you can use it to specify the range of topics that notifications are required for. This is done using the Select( SelectionMode, TopicSet ) method which may be used to add, replace, remove or clear selections.

Member Function Documentation

void PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.Select ( SelectionMode  mode,
TopicSet  selections 
)

Sends a request to the server to update the selection of topics that topic add notifications will be received for. As this is an asynchronous request to the server the update may not take effect immediately. Upon receiving the new selection set the server will check if there are any existing topics that match the selections (that did not match before) and send a separate add notification for each one. New topics that match the selections will be notified as and when they are added.

Parameters
modeIndicates the mode of the requested update which can be to add to current selections, replace all current selections or to remove some or all current selections.
selectionsA set of topic selector patterns which specifies the topic selections to update.

Implemented in PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.TopicNotifyTopicHandlerImpl.

void PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.SetNotificationDetails ( NotificationLevel  addLevel,
bool  notifyRemoval,
bool  notifyUpdate 
)

This can be used to set the notification details required.

If this is not called, then the default with be NotificationLevel.Minimum, with no deletions or updates notified.

This will send a message to the server requesting a change in the notification level and therefore should ideally be called before any call to Select( SelectionMode, TopicSet ) otherwise the effect will be delayed.

Parameters
addLevelThe required notification level for add notifications.
notifyRemovaltrue to request notifications of topic removals.
notifyUpdatetrue to request notifications of updates to those topic properties that can be changed after the topic has been created.

Implemented in PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.TopicNotifyTopicHandlerImpl.

void PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.SetNotificationLevel ( NotificationLevel  level)

This can be used to change the notification level from that initially specified.

This will send a message to the server requesting a change to the notification level and so may not take immediate effect.

Parameters
levelThe new notification level.

Implemented in PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.TopicNotifyTopicHandlerImpl.

Property Documentation

IDiffusionClientConnector PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.Connection
get

Returns the client connection.

bool PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.IsNotifyingRemoval
get

Indicates whether notifying topic removals.

bool PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.IsNotifyingUpdate
get

Indicates whether notifying topic property updates.

NotificationLevel PushTechnology.DiffusionCore.Connection.Connectors.ExternalClient.Notify.ITopicNotifyTopicHandler.NotificationLevel
get

Returns the current add notification level.