Show / Hide Table of Contents

Class TopicManager

Maintains the sequence of peer's that are interested in a topic.

Inheritance
Object
TopicManager
Inherited Members
Object.Equals(Object)
Object.Equals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Object.ReferenceEquals(Object, Object)
Object.ToString()
Namespace: PeerTalk.PubSub
Assembly: PeerTalk.dll
Syntax
public class TopicManager

Methods

| Improve this Doc View Source

AddInterest(String, Peer)

Indicate that the Peer is interested in the topic.

Declaration
public void AddInterest(string topic, Peer peer)
Parameters
Type Name Description
String topic

The topic of interest.

Peer peer

A Peer

Remarks

Duplicates are ignored.

| Improve this Doc View Source

Clear()

Remove all topics.

Declaration
public void Clear()
| Improve this Doc View Source

Clear(Peer)

Indicates that the peer is not interested in anything.

Declaration
public void Clear(Peer peer)
Parameters
Type Name Description
Peer peer

The Peer.s

| Improve this Doc View Source

GetPeers(String)

Get the peers interested in a topic.

Declaration
public IEnumerable<Peer> GetPeers(string topic)
Parameters
Type Name Description
String topic

The topic of interest or null for all topics.

Returns
Type Description
IEnumerable<Peer>

A sequence of Peer that are interested in the topic.

| Improve this Doc View Source

GetTopics(Peer)

Gets the topics that a peer is interested in

Declaration
public IEnumerable<string> GetTopics(Peer peer)
Parameters
Type Name Description
Peer peer

The Peer.

Returns
Type Description
IEnumerable<String>

A sequence of topics that the peer is interested in.

| Improve this Doc View Source

RemoveInterest(String, Peer)

Indicate that the Peer is not interested in the topic.

Declaration
public void RemoveInterest(string topic, Peer peer)
Parameters
Type Name Description
String topic

The topic of interest.

Peer peer

A Peer

  • Improve this Doc
  • View Source
Back to top Generated by DocFX