CCIMXDesktop
 
Loading...
Searching...
No Matches
timerservermonitoring.h
1#ifndef TIMERSERVERMONITORING_H
2#define TIMERSERVERMONITORING_H
3#include <QMap>
4#include <QString>
5#include <QObject>
6#include "TimeServerType.h"
7#include "core/server/DesktopServerBase.h"
9
11 Q_OBJECT
12public:
13 explicit TimerServerMonitoring(QObject* parent = nullptr);
21 void attach_server(TimerHandleServer* raw_server);
22
30 TimerHandleServer *install_server(const unsigned int runs_interval,
31 QString&& name,
32 ServerRunner &&functor);
33
39 void remove_server_name(const QString& name);
40
45 void remove_server_id(const ServerID& id);
46
52 TimerHandleServer* query_from_id(const ServerID& id);
53
54 void setServerState(const ServerID &id, bool st);
55
56signals:
57 void server_activate_once(const ServerID& id);
58 void server_finished(const ServerID& id);
59 void server_hanged(const ServerID& id);
60 void server_depatched_run(const ServerID& id);
61 void server_destoryed(const ServerID& id);
62
63private:
64 QMap<ServerID, TimerHandleServer*> timerServer;
65 const QString name {"Timer Monitoring Server"};
66
67private:
68 void run_connection_setup(TimerHandleServer* s);
69};
70
71#endif // TIMERSERVERMONITORING_H
The DesktopServerBase class notifies the backend Server for desktop with eventloop engaged in desktop...
Definition DesktopServerBase.h:12
Definition timerhandleserver.h:6
Definition timerservermonitoring.h:10
void attach_server(TimerHandleServer *raw_server)
attach_server
Definition timerservermonitoring.cpp:21
TimerHandleServer * install_server(const unsigned int runs_interval, QString &&name, ServerRunner &&functor)
install_server install the server directly
Definition timerservermonitoring.cpp:40
void remove_server_id(const ServerID &id)
remove_server_id session id
Definition timerservermonitoring.cpp:74
TimerHandleServer * query_from_id(const ServerID &id)
query_from_id query the server handle
Definition timerservermonitoring.cpp:91
void remove_server_name(const QString &name)
remove_server_name remove all the server with target name given
Definition timerservermonitoring.cpp:53