MythTV  master
Public Slots | Public Member Functions | Static Public Member Functions | Private Slots | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
MythRAOPDevice Class Reference

#include <mythraopdevice.h>

Inheritance diagram for MythRAOPDevice:
Inheritance graph
[legend]
Collaboration diagram for MythRAOPDevice:
Collaboration graph
[legend]

Public Slots

void TVPlaybackStarting (void)
 

Public Member Functions

 MythRAOPDevice ()
 
void DeleteAllClients (MythRAOPConnection *keep)
 
- Public Member Functions inherited from ServerPool
 ServerPool (QObject *parent=nullptr)
 
 ~ServerPool (void) override
 
bool listen (QList< QHostAddress > addrs, quint16 port, bool requireall=true, PoolServerType type=kTCPServer)
 
bool listen (QStringList addrs, quint16 port, bool requireall=true, PoolServerType type=kTCPServer)
 
bool listen (quint16 port, bool requireall=true, PoolServerType type=kTCPServer)
 
bool bind (QList< QHostAddress > addrs, quint16 port, bool requireall=true)
 
bool bind (QStringList addrs, quint16 port, bool requireall=true)
 
bool bind (quint16 port, bool requireall=true)
 
qint64 writeDatagram (const char *data, qint64 size, const QHostAddress &addr, quint16 port)
 
qint64 writeDatagram (const QByteArray &datagram, const QHostAddress &addr, quint16 port)
 
bool isListening (void) const
 
int maxPendingConnections (void) const
 
void setMaxPendingConnections (int n)
 
quint16 serverPort (void) const
 
QNetworkProxy proxy (void)
 
void setProxy (const QNetworkProxy &proxy)
 
void close (void)
 
int tryListeningPort (int baseport, int range=1)
 tryListeningPort More...
 
int tryBindingPort (int baseport, int range=1)
 tryBindingPort More...
 

Static Public Member Functions

static bool Create (void)
 
static void Cleanup (void)
 
static MythRAOPDeviceRAOPSharedInstance (void)
 
- Static Public Member Functions inherited from ServerPool
static void RefreshDefaultListen (void)
 
static QList< QHostAddress > DefaultListen (void)
 
static QList< QHostAddress > DefaultListenIPv4 (void)
 
static QList< QHostAddress > DefaultListenIPv6 (void)
 
static QList< QHostAddress > DefaultBroadcast (void)
 
static QList< QHostAddress > DefaultBroadcastIPv4 (void)
 
static QList< QHostAddress > DefaultBroadcastIPv6 (void)
 
static int tryListeningPort (QTcpServer *server, int baseport, int range=1, bool *isipv6=nullptr)
 tryListeningPort More...
 
static int tryBindingPort (QUdpSocket *socket, int baseport, int range=1, bool *isipv6=nullptr)
 tryBindingPort More...
 

Private Slots

void Start ()
 
void Stop ()
 
void newRaopConnection (QTcpSocket *client)
 
void deleteClient ()
 

Private Member Functions

 ~MythRAOPDevice (void) override
 
void Teardown (void)
 
bool RegisterForBonjour (void)
 

Private Attributes

QString m_name {"MythTV"}
 
QByteArray m_hardwareId
 
BonjourRegisterm_bonjour {nullptr}
 
bool m_valid {false}
 
QRecursiveMutex * m_lock {nullptr}
 
int m_setupPort {5000}
 
int m_basePort {0}
 
QList< MythRAOPConnection * > m_clients
 

Static Private Attributes

static MythRAOPDevicegMythRAOPDevice = nullptr
 
static QRecursiveMutex * gMythRAOPDeviceMutex = new QRecursiveMutex()
 
static MThreadgMythRAOPDeviceThread = nullptr
 

Additional Inherited Members

- Signals inherited from ServerPool
void newConnection (QTcpSocket *)
 
void newDatagram (QByteArray, QHostAddress, quint16)
 
- Protected Slots inherited from ServerPool
virtual void newUdpDatagram (void)
 
virtual void newTcpConnection (qintptr socket)
 

Detailed Description

Definition at line 16 of file mythraopdevice.h.

Constructor & Destructor Documentation

◆ MythRAOPDevice()

MythRAOPDevice::MythRAOPDevice ( )

Definition at line 89 of file mythraopdevice.cpp.

Referenced by Create().

◆ ~MythRAOPDevice()

MythRAOPDevice::~MythRAOPDevice ( void  )
overrideprivate

Definition at line 95 of file mythraopdevice.cpp.

Member Function Documentation

◆ Create()

bool MythRAOPDevice::Create ( void  )
static

Definition at line 26 of file mythraopdevice.cpp.

Referenced by main().

◆ Cleanup()

void MythRAOPDevice::Cleanup ( void  )
static

Definition at line 72 of file mythraopdevice.cpp.

◆ RAOPSharedInstance()

static MythRAOPDevice* MythRAOPDevice::RAOPSharedInstance ( void  )
inlinestatic

Definition at line 23 of file mythraopdevice.h.

◆ DeleteAllClients()

void MythRAOPDevice::DeleteAllClients ( MythRAOPConnection keep)

Definition at line 264 of file mythraopdevice.cpp.

Referenced by Teardown(), and TVPlaybackStarting().

◆ TVPlaybackStarting

void MythRAOPDevice::TVPlaybackStarting ( void  )
slot

Definition at line 202 of file mythraopdevice.cpp.

Referenced by newRaopConnection().

◆ Start

void MythRAOPDevice::Start ( )
privateslot

Definition at line 116 of file mythraopdevice.cpp.

Referenced by Create().

◆ Stop

void MythRAOPDevice::Stop ( )
privateslot

Definition at line 151 of file mythraopdevice.cpp.

Referenced by Create().

◆ newRaopConnection

void MythRAOPDevice::newRaopConnection ( QTcpSocket *  client)
privateslot

Definition at line 208 of file mythraopdevice.cpp.

Referenced by Start().

◆ deleteClient

void MythRAOPDevice::deleteClient ( )
privateslot

Definition at line 238 of file mythraopdevice.cpp.

Referenced by newRaopConnection().

◆ Teardown()

void MythRAOPDevice::Teardown ( void  )
private

Definition at line 101 of file mythraopdevice.cpp.

Referenced by Stop().

◆ RegisterForBonjour()

bool MythRAOPDevice::RegisterForBonjour ( void  )
private

Definition at line 156 of file mythraopdevice.cpp.

Referenced by Start().

Member Data Documentation

◆ gMythRAOPDevice

MythRAOPDevice * MythRAOPDevice::gMythRAOPDevice = nullptr
staticprivate

Definition at line 43 of file mythraopdevice.h.

Referenced by Cleanup(), and Create().

◆ gMythRAOPDeviceMutex

QRecursiveMutex * MythRAOPDevice::gMythRAOPDeviceMutex = new QRecursiveMutex()
staticprivate

Definition at line 44 of file mythraopdevice.h.

Referenced by Cleanup(), and Create().

◆ gMythRAOPDeviceThread

MThread * MythRAOPDevice::gMythRAOPDeviceThread = nullptr
staticprivate

Definition at line 45 of file mythraopdevice.h.

Referenced by Cleanup(), and Create().

◆ m_name

QString MythRAOPDevice::m_name {"MythTV"}
private

Definition at line 48 of file mythraopdevice.h.

Referenced by RegisterForBonjour().

◆ m_hardwareId

QByteArray MythRAOPDevice::m_hardwareId
private

Definition at line 49 of file mythraopdevice.h.

Referenced by MythRAOPDevice(), newRaopConnection(), and RegisterForBonjour().

◆ m_bonjour

BonjourRegister* MythRAOPDevice::m_bonjour {nullptr}
private

Definition at line 50 of file mythraopdevice.h.

Referenced by RegisterForBonjour(), and Teardown().

◆ m_valid

bool MythRAOPDevice::m_valid {false}
private

Definition at line 51 of file mythraopdevice.h.

Referenced by Start(), and Teardown().

◆ m_lock

QRecursiveMutex* MythRAOPDevice::m_lock {nullptr}
private

◆ m_setupPort

int MythRAOPDevice::m_setupPort {5000}
private

Definition at line 53 of file mythraopdevice.h.

Referenced by RegisterForBonjour(), and Start().

◆ m_basePort

int MythRAOPDevice::m_basePort {0}
private

Definition at line 54 of file mythraopdevice.h.

Referenced by RegisterForBonjour(), and Start().

◆ m_clients

QList<MythRAOPConnection*> MythRAOPDevice::m_clients
private

Definition at line 55 of file mythraopdevice.h.

Referenced by DeleteAllClients(), deleteClient(), and newRaopConnection().


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