MythTV  master
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Eventing Class Reference

#include <libmythupnp/eventing.h>

Inheritance diagram for Eventing:
[legend]
Collaboration diagram for Eventing:
[legend]

Public Member Functions

 Eventing (const QString &sExtensionName, QString sEventMethodName, const QString &sSharePath)
 
 ~Eventing () override
 
QStringList GetBasePaths () override
 
bool ProcessRequest (HTTPRequest *pRequest) override
 
short HoldEvents ()
 
short ReleaseEvents ()
 
void ExecutePostProcess () override
 
- Public Member Functions inherited from HttpServerExtension
 HttpServerExtension (QString sName, QString sSharePath)
 
 ~HttpServerExtension () override=default
 
virtual bool ProcessOptions (HTTPRequest *pRequest)
 Handle an OPTIONS request. More...
 
virtual int GetSocketTimeout () const
 
- Public Member Functions inherited from StateVariables
 StateVariables ()=default
 
virtual ~StateVariables ()
 
void AddVariable (StateVariableBase *pBase)
 
template<class T >
bool SetValue (const QString &sName, const T &value)
 
template<class T >
GetValue (const QString &sName)
 
uint BuildNotifyBody (QTextStream &ts, TaskTime ttLastNotified) const
 
- Public Member Functions inherited from IPostProcess
virtual ~IPostProcess ()=default
 
- Public Member Functions inherited from UPnpServiceImpl
 UPnpServiceImpl ()=default
 
virtual ~UPnpServiceImpl ()=default
 
void RegisterService (UPnpDevice *device)
 Creates a UPnpService and adds it to the UPnpDevice's list of services. More...
 

Protected Member Functions

void Notify () override
 
void NotifySubscriber (SubscriberInfo *pInfo)
 
void HandleSubscribe (HTTPRequest *pRequest)
 
void HandleUnsubscribe (HTTPRequest *pRequest)
 
QString GetServiceEventURL () override
 Provides the URL of the event portion of the service. More...
 
- Protected Member Functions inherited from UPnpServiceImpl
virtual QString GetServiceType (void)=0
 Provices the schema urn. More...
 
virtual QString GetServiceId (void)=0
 Provides the device specific urn. More...
 
virtual QString GetServiceControlURL (void)=0
 Provices the base URL for control commands. More...
 
virtual QString GetServiceDescURL (void)=0
 Provices the URL of the service description XML. More...
 

Protected Attributes

QMutex m_mutex
 
QString m_sEventMethodName
 
Subscribers m_subscribers
 
std::chrono::seconds m_nSubscriptionDuration {30min}
 
short m_nHoldCount {0}
 
SubscriberInfom_pInitializeSubscriber {nullptr}
 
- Protected Attributes inherited from StateVariables
SVMap m_map
 

Additional Inherited Members

- Public Attributes inherited from HttpServerExtension
QString m_sName
 
QString m_sSharePath
 
int m_nSocketTimeout { -1 }
 
uint m_nSupportedMethods
 
- Protected Types inherited from StateVariables
using SVMap = QMap< QString, StateVariableBase * >
 

Detailed Description

Definition at line 245 of file eventing.h.

Constructor & Destructor Documentation

◆ Eventing()

Eventing::Eventing ( const QString &  sExtensionName,
QString  sEventMethodName,
const QString &  sSharePath 
)

Definition at line 65 of file eventing.cpp.

◆ ~Eventing()

Eventing::~Eventing ( )
override

Definition at line 80 of file eventing.cpp.

Member Function Documentation

◆ Notify()

void Eventing::Notify ( )
overrideprotectedvirtual

Implements StateVariables.

Definition at line 323 of file eventing.cpp.

Referenced by ReleaseEvents().

◆ NotifySubscriber()

void Eventing::NotifySubscriber ( SubscriberInfo pInfo)
protected

Definition at line 359 of file eventing.cpp.

Referenced by ExecutePostProcess(), and Notify().

◆ HandleSubscribe()

void Eventing::HandleSubscribe ( HTTPRequest pRequest)
protected

Definition at line 194 of file eventing.cpp.

Referenced by ProcessRequest().

◆ HandleUnsubscribe()

void Eventing::HandleUnsubscribe ( HTTPRequest pRequest)
protected

Definition at line 293 of file eventing.cpp.

Referenced by ProcessRequest().

◆ GetServiceEventURL()

QString Eventing::GetServiceEventURL ( )
inlineoverrideprotectedvirtual

Provides the URL of the event portion of the service.

Reimplemented from UPnpServiceImpl.

Definition at line 273 of file eventing.h.

◆ GetBasePaths()

QStringList Eventing::GetBasePaths ( )
overridevirtual

◆ ProcessRequest()

bool Eventing::ProcessRequest ( HTTPRequest pRequest)
overridevirtual

Implements HttpServerExtension.

Reimplemented in UPnpCDS, UPnpCMGR, UPnpMSRR, and MythFEXML.

Definition at line 146 of file eventing.cpp.

Referenced by UPnpMSRR::ProcessRequest(), UPnpCMGR::ProcessRequest(), and UPnpCDS::ProcessRequest().

◆ HoldEvents()

short Eventing::HoldEvents ( )
inline

Definition at line 91 of file eventing.cpp.

◆ ReleaseEvents()

short Eventing::ReleaseEvents ( )
inline

Definition at line 116 of file eventing.cpp.

◆ ExecutePostProcess()

void Eventing::ExecutePostProcess ( )
overridevirtual

Implements IPostProcess.

Definition at line 177 of file eventing.cpp.

Member Data Documentation

◆ m_mutex

QMutex Eventing::m_mutex
protected

Definition at line 253 of file eventing.h.

Referenced by HoldEvents(), Notify(), and ReleaseEvents().

◆ m_sEventMethodName

QString Eventing::m_sEventMethodName
protected

Definition at line 255 of file eventing.h.

Referenced by ProcessRequest().

◆ m_subscribers

Subscribers Eventing::m_subscribers
protected

Definition at line 256 of file eventing.h.

Referenced by HandleSubscribe(), HandleUnsubscribe(), Notify(), and ~Eventing().

◆ m_nSubscriptionDuration

std::chrono::seconds Eventing::m_nSubscriptionDuration {30min}
protected

Definition at line 258 of file eventing.h.

Referenced by HandleSubscribe().

◆ m_nHoldCount

short Eventing::m_nHoldCount {0}
protected

Definition at line 260 of file eventing.h.

Referenced by HoldEvents(), and ReleaseEvents().

◆ m_pInitializeSubscriber

SubscriberInfo* Eventing::m_pInitializeSubscriber {nullptr}
protected

Definition at line 262 of file eventing.h.

Referenced by ExecutePostProcess(), and HandleSubscribe().


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