MythTV
master
|
#include <httpserver.h>
Public Member Functions | |
HttpServer () | |
~HttpServer () override | |
void | RegisterExtension (HttpServerExtension *pExtension) |
void | UnregisterExtension (HttpServerExtension *pExtension) |
void | DelegateRequest (HTTPRequest *pRequest) |
uint | GetSocketTimeout (HTTPRequest *pRequest) const |
Get the idle socket timeout value for the relevant extension. More... | |
QString | GetSharePath (void) const |
bool | IsRunning (void) const |
![]() | |
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 QString | GetPlatform (void) |
static QString | GetServerVersion (void) |
![]() | |
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... | |
Protected Slots | |
void | newTcpConnection (qintptr socket) override |
![]() | |
virtual void | newUdpDatagram (void) |
virtual void | newTcpConnection (qintptr socket) |
Protected Attributes | |
QReadWriteLock | m_rwlock |
HttpServerExtensionList | m_extensions |
QMultiMap< QString, HttpServerExtension * > | m_basePaths |
QString | m_sSharePath |
MThreadPool | m_threadPool |
bool | m_running { true } |
QSslConfiguration | m_sslConfig |
const QString | m_privateToken |
Static Protected Attributes | |
static QMutex | s_platformLock |
static QString | s_platform |
Private Member Functions | |
void | LoadSSLConfig () |
Additional Inherited Members | |
![]() | |
void | newConnection (QTcpSocket *) |
void | newDatagram (QByteArray, QHostAddress, quint16) |
Definition at line 112 of file httpserver.h.
HttpServer::HttpServer | ( | ) |
Definition at line 116 of file httpserver.cpp.
|
override |
Definition at line 170 of file httpserver.cpp.
void HttpServer::RegisterExtension | ( | HttpServerExtension * | pExtension | ) |
Definition at line 321 of file httpserver.cpp.
Referenced by HttpServer(), MediaServer::Init(), UPnp::Initialize(), MediaRenderer::MediaRenderer(), and run_backend().
void HttpServer::UnregisterExtension | ( | HttpServerExtension * | pExtension | ) |
Definition at line 344 of file httpserver.cpp.
void HttpServer::DelegateRequest | ( | HTTPRequest * | pRequest | ) |
Definition at line 367 of file httpserver.cpp.
Referenced by HttpWorker::run().
uint HttpServer::GetSocketTimeout | ( | HTTPRequest * | pRequest | ) | const |
Get the idle socket timeout value for the relevant extension.
Definition at line 424 of file httpserver.cpp.
Referenced by HttpWorker::run().
|
inline |
Definition at line 128 of file httpserver.h.
Referenced by UPnp::Initialize(), and MediaRenderer::MediaRenderer().
|
inline |
Definition at line 133 of file httpserver.h.
Referenced by HttpWorker::run().
|
static |
Definition at line 278 of file httpserver.cpp.
Referenced by GetServerVersion().
|
static |
Definition at line 288 of file httpserver.cpp.
Referenced by HTTPRequest::BuildResponseHeader(), ServerSideScripting::EvaluatePage(), UPnpSearchTask::SendMsg(), and UPnpNotifyTask::SendNotifyMsg().
|
overrideprotectedslot |
Definition at line 301 of file httpserver.cpp.
|
private |
Definition at line 184 of file httpserver.cpp.
Referenced by HttpServer().
|
mutableprotected |
Definition at line 145 of file httpserver.h.
Referenced by DelegateRequest(), GetSocketTimeout(), RegisterExtension(), UnregisterExtension(), and ~HttpServer().
|
protected |
Definition at line 146 of file httpserver.h.
Referenced by DelegateRequest(), RegisterExtension(), UnregisterExtension(), and ~HttpServer().
|
protected |
Definition at line 148 of file httpserver.h.
Referenced by DelegateRequest(), GetSocketTimeout(), RegisterExtension(), and UnregisterExtension().
|
protected |
Definition at line 149 of file httpserver.h.
Referenced by HttpServer().
|
protected |
Definition at line 150 of file httpserver.h.
Referenced by HttpServer(), newTcpConnection(), and ~HttpServer().
Definition at line 151 of file httpserver.h.
Referenced by ~HttpServer().
|
staticprotected |
Definition at line 153 of file httpserver.h.
Referenced by GetPlatform(), and HttpServer().
|
staticprotected |
Definition at line 154 of file httpserver.h.
Referenced by GetPlatform(), and HttpServer().
|
protected |
Definition at line 157 of file httpserver.h.
Referenced by LoadSSLConfig(), and newTcpConnection().
|
protected |
Definition at line 160 of file httpserver.h.