OPAL  Version 3.10.10
SIPHandlersList Class Reference

#include <handlers.h>

Public Member Functions

void Append (SIPHandler *handler)
 
void Remove (SIPHandler *handler)
 
void Update (SIPHandler *handler)
 
bool DeleteObjectsToBeRemoved ()
 
PSafePtr< SIPHandlerGetFirstHandler (PSafetyMode mode=PSafeReference) const
 
unsigned GetCount (SIP_PDU::Methods meth, const PString &eventPackage=PString::Empty()) const
 
PStringList GetAddresses (bool includeOffline, SIP_PDU::Methods meth, const PString &eventPackage=PString::Empty()) const
 
PSafePtr< SIPHandlerFindSIPHandlerByCallID (const PString &callID, PSafetyMode m)
 
PSafePtr< SIPHandlerFindSIPHandlerByAuthRealm (const PString &authRealm, PSafetyMode m)
 
PSafePtr< SIPHandlerFindSIPHandlerByAuthRealm (const PString &authRealm, const PString &userName, PSafetyMode m)
 
PSafePtr< SIPHandlerFindSIPHandlerByUrl (const PURL &url, SIP_PDU::Methods meth, PSafetyMode m)
 
PSafePtr< SIPHandlerFindSIPHandlerByUrl (const PURL &url, SIP_PDU::Methods meth, const PString &eventPackage, PSafetyMode m)
 
PSafePtr< SIPHandlerFindSIPHandlerByDomain (const PString &name, SIP_PDU::Methods meth, PSafetyMode m)
 

Protected Types

typedef SIPHandler::IndexMap IndexMap
 

Protected Member Functions

void RemoveIndexes (SIPHandler *handler)
 
PSafePtr< SIPHandlerFindBy (IndexMap &by, const PString &key, PSafetyMode m)
 

Protected Attributes

PMutex m_extraMutex
 
PSafeList< SIPHandlerm_handlersList
 
IndexMap m_byCallID
 
IndexMap m_byAorAndPackage
 
IndexMap m_byAuthIdAndRealm
 
IndexMap m_byAorUserAndRealm
 

Detailed Description

This dictionary is used both to contain the active and successful registrations, and subscriptions.

Member Typedef Documentation

◆ IndexMap

Member Function Documentation

◆ Append()

void SIPHandlersList::Append ( SIPHandler handler)

Append a new handler to the list

◆ DeleteObjectsToBeRemoved()

bool SIPHandlersList::DeleteObjectsToBeRemoved ( )
inline

Clean up lists of handler.

◆ FindBy()

PSafePtr<SIPHandler> SIPHandlersList::FindBy ( IndexMap by,
const PString &  key,
PSafetyMode  m 
)
protected

◆ FindSIPHandlerByAuthRealm() [1/2]

PSafePtr<SIPHandler> SIPHandlersList::FindSIPHandlerByAuthRealm ( const PString &  authRealm,
PSafetyMode  m 
)

Find the SIPHandler object with the specified authRealm

◆ FindSIPHandlerByAuthRealm() [2/2]

PSafePtr<SIPHandler> SIPHandlersList::FindSIPHandlerByAuthRealm ( const PString &  authRealm,
const PString &  userName,
PSafetyMode  m 
)

Find the SIPHandler object with the specified authRealm & user

◆ FindSIPHandlerByCallID()

PSafePtr<SIPHandler> SIPHandlersList::FindSIPHandlerByCallID ( const PString &  callID,
PSafetyMode  m 
)

Find the SIPHandler object with the specified callID

◆ FindSIPHandlerByDomain()

PSafePtr<SIPHandler> SIPHandlersList::FindSIPHandlerByDomain ( const PString &  name,
SIP_PDU::Methods  meth,
PSafetyMode  m 
)

Find the SIPHandler object with the specified registration host. For example, in the above case, the name parameter could be "sip.seconix.com" or "seconix.com".

◆ FindSIPHandlerByUrl() [1/2]

PSafePtr<SIPHandler> SIPHandlersList::FindSIPHandlerByUrl ( const PURL &  url,
SIP_PDU::Methods  meth,
PSafetyMode  m 
)

Find the SIPHandler object with the specified URL. The url is the registration address, for example, 6001@.nosp@m.sip..nosp@m.secon.nosp@m.ix.c.nosp@m.om when registering 6001 to sip.seconix.com with realm seconix.com or 6001@.nosp@m.seco.nosp@m.nix.c.nosp@m.om when registering 6001@.nosp@m.seco.nosp@m.nix.c.nosp@m.om to sip.seconix.com

◆ FindSIPHandlerByUrl() [2/2]

PSafePtr<SIPHandler> SIPHandlersList::FindSIPHandlerByUrl ( const PURL &  url,
SIP_PDU::Methods  meth,
const PString &  eventPackage,
PSafetyMode  m 
)

◆ GetAddresses()

PStringList SIPHandlersList::GetAddresses ( bool  includeOffline,
SIP_PDU::Methods  meth,
const PString &  eventPackage = PString::Empty() 
) const

Return a list of the active address of records for each handler.

◆ GetCount()

unsigned SIPHandlersList::GetCount ( SIP_PDU::Methods  meth,
const PString &  eventPackage = PString::Empty() 
) const

Return the number of registered accounts

◆ GetFirstHandler()

PSafePtr<SIPHandler> SIPHandlersList::GetFirstHandler ( PSafetyMode  mode = PSafeReference) const
inline

Get the first handler in the list. Further enumeration may be done by the ++operator on the safe pointer.

◆ Remove()

void SIPHandlersList::Remove ( SIPHandler handler)

Remove a handler from the list. Handler is not immediately deleted but marked for deletion later by DeleteObjectsToBeRemoved() when all references are done with the handler.

◆ RemoveIndexes()

void SIPHandlersList::RemoveIndexes ( SIPHandler handler)
protected

◆ Update()

void SIPHandlersList::Update ( SIPHandler handler)

Update indexes for handler in the list

Field Documentation

◆ m_byAorAndPackage

IndexMap SIPHandlersList::m_byAorAndPackage
protected

◆ m_byAorUserAndRealm

IndexMap SIPHandlersList::m_byAorUserAndRealm
protected

◆ m_byAuthIdAndRealm

IndexMap SIPHandlersList::m_byAuthIdAndRealm
protected

◆ m_byCallID

IndexMap SIPHandlersList::m_byCallID
protected

◆ m_extraMutex

PMutex SIPHandlersList::m_extraMutex
protected

◆ m_handlersList

PSafeList<SIPHandler> SIPHandlersList::m_handlersList
protected

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