|
MythTV master
|
#include <libmythbase/http/mythhttpinstance.h>
Static Public Member Functions | |
| static void | EnableHTTPService (bool Enable=true) |
| Signals to the MythHTTPServer instance whether to start or stop listening. More... | |
| static void | StopHTTPService () |
| Stop and delete the MythHTTPServer instance. More... | |
| static void | AddPaths (const QStringList &Paths) |
| Add path(s) for the MythHTTPServer instance to handle. More... | |
| static void | RemovePaths (const QStringList &Paths) |
| Remove path(s) from the MythHTTPServer instance. More... | |
| static void | AddHandlers (const HTTPHandlers &Handlers) |
| Add function handlers for specific paths. More... | |
| static void | RemoveHandlers (const HTTPHandlers &Handlers) |
| static void | Addservices (const HTTPServices &Services) |
| static void | RemoveServices (const HTTPServices &Services) |
| static void | AddErrorPageHandler (const HTTPHandler &Handler) |
Private Member Functions | |
| MythHTTPInstance () | |
| ~MythHTTPInstance () | |
Static Private Member Functions | |
| static MythHTTPInstance & | Instance () |
Private Attributes | |
| MythHTTPServer * | m_httpServer { nullptr } |
| MThread * | m_httpServerThread { nullptr } |
Definition at line 11 of file mythhttpinstance.h.
|
private |
Definition at line 13 of file mythhttpinstance.cpp.
|
private |
Definition at line 35 of file mythhttpinstance.cpp.
|
static |
Definition at line 116 of file mythhttpinstance.cpp.
Referenced by main(), run_backend(), and run_setup_webserver().
|
static |
Add function handlers for specific paths.
The functions will provide simple dynamic content, returning either a valid response to be processed or a null response to indicate that the path was not handled.
Definition at line 96 of file mythhttpinstance.cpp.
Referenced by MythHTTPScopedInstance::MythHTTPScopedInstance().
|
static |
Add path(s) for the MythHTTPServer instance to handle.
This is the default implementation. The server will serve any files in the given path(s) without limit (i.e. no authorisation etc)
Definition at line 79 of file mythhttpinstance.cpp.
|
static |
Definition at line 106 of file mythhttpinstance.cpp.
Referenced by main(), run_backend(), and run_setup_webserver().
Signals to the MythHTTPServer instance whether to start or stop listening.
The server is not deleted.
Definition at line 69 of file mythhttpinstance.cpp.
Referenced by MythHTTPScopedInstance::MythHTTPScopedInstance().
|
staticprivate |
Definition at line 7 of file mythhttpinstance.cpp.
Referenced by AddErrorPageHandler(), AddHandlers(), AddPaths(), Addservices(), EnableHTTPService(), RemoveHandlers(), RemovePaths(), RemoveServices(), and StopHTTPService().
|
static |
Definition at line 101 of file mythhttpinstance.cpp.
|
static |
Remove path(s) from the MythHTTPServer instance.
Definition at line 86 of file mythhttpinstance.cpp.
|
static |
Definition at line 111 of file mythhttpinstance.cpp.
|
static |
Stop and delete the MythHTTPServer instance.
This should be used to cleanup the HTTP server when the application is terminating. To start or stop the server during the application lifetime use EnableHTTPService.
Definition at line 51 of file mythhttpinstance.cpp.
Referenced by MythHTTPScopedInstance::~MythHTTPScopedInstance().
|
private |
Definition at line 31 of file mythhttpinstance.h.
Referenced by AddErrorPageHandler(), AddHandlers(), AddPaths(), Addservices(), EnableHTTPService(), MythHTTPInstance(), RemoveHandlers(), RemovePaths(), RemoveServices(), StopHTTPService(), and ~MythHTTPInstance().
|
private |
Definition at line 32 of file mythhttpinstance.h.
Referenced by MythHTTPInstance(), StopHTTPService(), and ~MythHTTPInstance().