Interface ISubscriptionDefinition
Defines a subscription that matches topics and maps them to agents.
public interface ISubscriptionDefinition
Properties
Id
Gets the unique identifier of the subscription.
string Id { get; }
Property Value
Methods
Equals(ISubscriptionDefinition?)
Determines whether the specified subscription is equal to the current subscription.
bool Equals(ISubscriptionDefinition? other)
Parameters
other
ISubscriptionDefinitionThe subscription to compare.
Returns
- bool
true
if the subscriptions are equal; otherwise,false
.
Equals(object?)
Determines whether the specified object is equal to the current subscription.
bool Equals(object? obj)
Parameters
obj
objectThe object to compare with the current instance.
Returns
- bool
true
if the specified object is equal to this instance; otherwise,false
.
GetHashCode()
Returns a hash code for this subscription.
int GetHashCode()
Returns
- int
A hash code for the subscription.
MapToAgent(TopicId)
Maps a TopicId to an AgentId.
Should only be called if Matches(TopicId) returns true
.
AgentId MapToAgent(TopicId topic)
Parameters
topic
TopicIdThe topic to map.
Returns
Matches(TopicId)
Checks if a given TopicId matches the subscription.
bool Matches(TopicId topic)
Parameters
topic
TopicIdThe topic to check.
Returns
- bool
true
if the topic matches the subscription; otherwise,false
.