reSIProcate
SIP stack, Dialog Usage Manager and related libraries
Loading...
Searching...
No Matches
resip::BasicDomainMatcher Class Reference

#include <BasicDomainMatcher.hxx>

Inheritance diagram for resip::BasicDomainMatcher:
[legend]

Public Member Functions

 BasicDomainMatcher ()
 
virtual ~BasicDomainMatcher ()
 
virtual bool isMyDomain (const Data &domain) const
 Returns true iff domain matches one of the domains that this TransactionUser is responsible for.
 
virtual void addDomain (const Data &domain)
 Adds a domain to the set of domains that this TransactionUser is responsible for.
 
virtual void removeDomain (const Data &domain)
 Removes a domain from the set of domains that this TransactionUser is responsible for.
 

Detailed Description

Definition at line 14 of file BasicDomainMatcher.hxx.

Constructor & Destructor Documentation

◆ BasicDomainMatcher()

BasicDomainMatcher::BasicDomainMatcher ( )

Definition at line 7 of file BasicDomainMatcher.cxx.

◆ ~BasicDomainMatcher()

BasicDomainMatcher::~BasicDomainMatcher ( )
virtual

Definition at line 12 of file BasicDomainMatcher.cxx.

Member Function Documentation

◆ addDomain()

void BasicDomainMatcher::addDomain ( const Data &  domain)
virtual

Adds a domain to the set of domains that this TransactionUser is responsible for.

Note
The comparison performed is case-sensitive; make sure you lower-case everything you put in here.
Todo:
Make this case-insensitive.
Warning
This method is NOT thread-safe. mDomainList is accessed from both the thread that queues to the TU (iff a DomainIsMe MessageFilterRule is used) and from within the TU itself. The only way calling this is safe, is if you can ensure both of these threads are not calling isMyDomain when you call this method. For example an application that does NOT use a DomainIsMe MessageFilterRule and that posts the addDomain call to the TU processing thread for execution there, will be thread safe. This API is also safe to call before any of the processing threads have been started.

Implements resip::DomainMatcher.

Definition at line 24 of file BasicDomainMatcher.cxx.

◆ isMyDomain()

bool BasicDomainMatcher::isMyDomain ( const Data &  domain) const
virtual

Returns true iff domain matches one of the domains that this TransactionUser is responsible for.

(added with addDomain).

Parameters
domainThe domain name to check.
Returns
True iff this TransactionUser is responsible for domain.
Note
The comparison performed is case-sensitive; make sure you lower-case everything you put in here.

Implements resip::DomainMatcher.

Reimplemented in resip::ExtendedDomainMatcher.

Definition at line 17 of file BasicDomainMatcher.cxx.

◆ removeDomain()

void BasicDomainMatcher::removeDomain ( const Data &  domain)
virtual

Removes a domain from the set of domains that this TransactionUser is responsible for.

Note
This API will lowercase the domain when searching for the domain to remove
Warning
This method is NOT thread-safe. mDomainList is accessed from both the thread that queues to the TU (iff a DomainIsMe MessageFilterRule is used) and from within the TU itself. The only way calling this is safe, is if you can ensure both of these threads are not calling isMyDomain when you call this method. For example an application that does NOT use a DomainIsMe MessageFilterRule and that posts the removeDomain call to the TU processing thread (ie: DUMThread) for execution there, will be thread safe.

Implements resip::DomainMatcher.

Definition at line 31 of file BasicDomainMatcher.cxx.


The documentation for this class was generated from the following files: