forked from yavdr/vdr-plugin-restfulapi
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathserverthread.h
53 lines (45 loc) · 1.1 KB
/
serverthread.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/*
* serverthread.h: JSONAPI plugin for the Video Disk Recorder
*
* See the README file for copyright information and how to reach the author.
*
*/
#ifndef __SERVERTHREAD_H
#define __SERVERTHREAD_H
#include <cxxtools/http/server.h>
#include <cxxtools/http/request.h>
#include <cxxtools/http/reply.h>
#include <cxxtools/http/responder.h>
#include <cxxtools/eventloop.h>
#include <cxxtools/arg.h>
#include <cxxtools/jsonserializer.h>
#include <cxxtools/regex.h>
#include <unistd.h>
#include "info.h"
#include "channels.h"
#include "events.h"
#include "recordings.h"
#include "remote.h"
#include "timers.h"
#include "osd.h"
#include "searchtimers.h"
#include "epgsearch.h"
#include "audio.h"
using namespace std;
class cServerThread : public cThread {
private:
bool active;
std::string listenIp;
unsigned short int listenPort;
cxxtools::EventLoop loop;
cxxtools::http::Server *server;
void Action(void);
public:
cServerThread() { };
~cServerThread();
void Initialize();
void StartUpdate();
bool isActive() { return active; };
void Stop();
};
#endif //__SERVERTHREAD_H