Diffusion .NET Classic API - Core and Common  5.9.4
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap Class Reference

This is used to represent the mapping of topic aliases to topic names for a particular server connection. The aliases therefore represent the alias of the topic at the server and not locally. More...

Inheritance diagram for PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap:
PushTechnology.DiffusionCore.Messaging.IMessageHeaderTransformer

Public Member Functions

void Clear ()
 Clear all maps. More...
 
void Map (string topicName, string alias)
 Records a mapping of a topic name to an alias. If there is already a mapping for the alias to a different topic, it is replaced. More...
 
string GetAlias (string topicName)
 Return an alias for the given topic name. More...
 
string GetTopicName (string alias)
 Return a topic name for the given alias. More...
 
bool Unmap (string alias)
 Unmaps a topic from the various maps. More...
 
override string ToString ()
 Returns a string that represents the current object. More...
 

Detailed Description

This is used to represent the mapping of topic aliases to topic names for a particular server connection. The aliases therefore represent the alias of the topic at the server and not locally.

When an ITL is received for a topic which specifies an alias then an entry will be created. Entries could be removed on unsubscription but the processing required for that is not really justified. It is better to let the maps exist for the duration of a connection as Topic to alias maps for a server are guaranteed.

Member Function Documentation

void PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap.Clear ( )

Clear all maps.

string PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap.GetAlias ( string  topicName)

Return an alias for the given topic name.

Parameters
topicNameThe topic name.
Returns
The alias for the topic name, or null if no mapping exists for the topic name.
string PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap.GetTopicName ( string  alias)

Return a topic name for the given alias.

Parameters
alias
Returns
void PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap.Map ( string  topicName,
string  alias 
)

Records a mapping of a topic name to an alias. If there is already a mapping for the alias to a different topic, it is replaced.

Parameters
topicName
alias
override string PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap.ToString ( )

Returns a string that represents the current object.

Returns
A string that represents the current object.
bool PushTechnology.DiffusionCore.Messaging.Topic.TopicAliasMap.Unmap ( string  alias)

Unmaps a topic from the various maps.

Parameters
alias
Returns