|
Ring Daemon
|
#include <pres_sub_client.h>

Public Member Functions | |
| void | decLock () |
| void | enable (bool flag) |
| Enable the monitoring and report signal to the client. | |
| std::string_view | getLineStatus () |
| A message from the URIs. | |
| SIPPresence * | getPresence () |
| Get associated parent presence_module. | |
| std::string_view | getURI () |
| Return the pres_client URI. | |
| void | incLock () |
| TODO: explain this: | |
| bool | isPresent () |
| Is the buddy present. | |
| bool | isSubscribed () |
| Return the monitor variable. | |
| bool | lock () |
| Data lock function. | |
| bool | match (PresSubClient *b) |
| Compare with another pres_client's uris. | |
| PresSubClient (const std::string &uri, SIPPresence *pres) | |
| Constructor. | |
| bool | subscribe () |
| Send a SUBCRIBE to the PXB or directly to a pres_client in the IP2IP context. | |
| void | unlock () |
| Data unlock function. | |
| bool | unsubscribe () |
| Send a SUBCRIBE to the PXB or directly to a pres_client in the IP2IP context but the 0s timeout make the dialog expire immediately. | |
| ~PresSubClient () | |
| Destructor. | |
Definition at line 39 of file pres_sub_client.h.
| jami::PresSubClient::PresSubClient | ( | const std::string & | uri, |
| SIPPresence * | pres | ||
| ) |
Constructor.
| uri | SIP uri of remote user that we want to subscribe, |
Definition at line 314 of file pres_sub_client.cpp.
References jami::emitSignal(), jami::SIPPresence::getAccount(), and jami::SIPAccount::getFromUri().

| jami::PresSubClient::~PresSubClient | ( | ) |
Destructor.
Process the the unsubscription before the destruction.
Definition at line 339 of file pres_sub_client.cpp.
References jami::emitSignal(), JAMI_DBG, and unsubscribe().

|
inline |
Definition at line 108 of file pres_sub_client.h.
Enable the monitoring and report signal to the client.
The PBX server must approve and maintain the subrciption before the pres_client is added in the pres_client list.
| flag | State of subscription. True if active. |
Definition at line 413 of file pres_sub_client.cpp.
References jami::SIPPresence::addPresSubClient(), jami::emitSignal(), getURI(), and JAMI_DBG.

| std::string_view jami::PresSubClient::getLineStatus | ( | ) |
A message from the URIs.
Definition at line 372 of file pres_sub_client.cpp.
References jami::emitSignal().

| SIPPresence * jami::PresSubClient::getPresence | ( | ) |
Get associated parent presence_module.
Definition at line 360 of file pres_sub_client.cpp.
| std::string_view jami::PresSubClient::getURI | ( | ) |
Return the pres_client URI.
Definition at line 354 of file pres_sub_client.cpp.
References jami::emitSignal().
Referenced by enable(), and match().

|
inline |
TODO: explain this:
Definition at line 107 of file pres_sub_client.h.
| bool jami::PresSubClient::isPresent | ( | ) |
Is the buddy present.
Definition at line 366 of file pres_sub_client.cpp.
| bool jami::PresSubClient::isSubscribed | ( | ) |
Return the monitor variable.
Definition at line 348 of file pres_sub_client.cpp.
| bool jami::PresSubClient::lock | ( | ) |
Data lock function.
Definition at line 429 of file pres_sub_client.cpp.
References jami::emitSignal(), JAMI_DBG, PRESENCE_CLIENT_LOCK_FLAG, PRESENCE_LOCK_FLAG, jami::SIPPresence::tryLock(), and jami::SIPPresence::unlock().
Referenced by unsubscribe().

| bool jami::PresSubClient::match | ( | PresSubClient * | b | ) |
Compare with another pres_client's uris.
| b | Other pres_client pointer |
Definition at line 631 of file pres_sub_client.cpp.
References jami::emitSignal(), and getURI().

| bool jami::PresSubClient::subscribe | ( | ) |
Send a SUBCRIBE to the PXB or directly to a pres_client in the IP2IP context.
Definition at line 523 of file pres_sub_client.cpp.
References jami::sip_utils::createRouteSet(), jami::emitSignal(), jami::SIPPresence::getAccount(), jami::SIPAccount::getCredentialCount(), jami::SIPAccount::getCredInfo(), jami::SIPAccount::getFromUri(), jami::SIPPresence::getPool(), jami::SIPAccount::getRegistrationInfo(), jami::SIPAccount::getServiceRoute(), jami::SIPAccount::hasCredentials(), jami::SIPAccount::hasServiceRoute(), JAMI_DBG, JAMI_ERR, and JAMI_WARN.
Referenced by jami::SIPPresence::subscribeClient().

| void jami::PresSubClient::unlock | ( | ) |
Data unlock function.
Definition at line 466 of file pres_sub_client.cpp.
References jami::emitSignal(), PRESENCE_CLIENT_LOCK_FLAG, PRESENCE_LOCK_FLAG, and jami::SIPPresence::unlock().
Referenced by unsubscribe().

| bool jami::PresSubClient::unsubscribe | ( | ) |
Send a SUBCRIBE to the PXB or directly to a pres_client in the IP2IP context but the 0s timeout make the dialog expire immediately.
Definition at line 476 of file pres_sub_client.cpp.
References jami::emitSignal(), jami::SIPPresence::fillDoc(), JAMI_WARN, lock(), and unlock().
Referenced by ~PresSubClient().
