Fawkes API
Fawkes Development Version
backendinfo-rest-api.h
1
2
/***************************************************************************
3
* backendinfo-rest-api.h - Backend Info REST API
4
*
5
* Created: Mon Apr 09 15:42:54 2018
6
* Copyright 2006-2018 Tim Niemueller [www.niemueller.de]
7
****************************************************************************/
8
9
/* This program is free software; you can redistribute it and/or modify
10
* it under the terms of the GNU General Public License as published by
11
* the Free Software Foundation; either version 2 of the License, or
12
* (at your option) any later version.
13
*
14
* This program is distributed in the hope that it will be useful,
15
* but WITHOUT ANY WARRANTY; without even the implied warranty of
16
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17
* GNU Library General Public License for more details.
18
*
19
* Read the full text in the LICENSE.GPL file in the doc directory.
20
*/
21
22
#pragma once
23
24
#include "model/Backend.h"
25
26
#include <aspect/configurable.h>
27
#include <aspect/logging.h>
28
#include <aspect/webview.h>
29
#include <core/threading/thread.h>
30
#include <webview/rest_api.h>
31
#include <webview/rest_array.h>
32
33
class
BackendInfoRestApi
:
public
fawkes::Thread
,
34
public
fawkes::ConfigurableAspect
,
35
public
fawkes::LoggingAspect
,
36
public
fawkes::WebviewAspect
37
{
38
public
:
39
BackendInfoRestApi
();
40
~BackendInfoRestApi
();
41
42
virtual
void
init
();
43
virtual
void
loop
();
44
virtual
void
finalize
();
45
46
private
:
47
WebviewRestArray<Backend>
cb_list_backends();
48
49
private
:
50
fawkes::WebviewRestApi
* rest_api_;
51
WebviewRestArray<Backend>
backends_;
52
};
BackendInfoRestApi::loop
virtual void loop()
Code to execute in the thread.
Definition:
backendinfo-rest-api.cpp:94
BackendInfoRestApi::BackendInfoRestApi
BackendInfoRestApi()
Constructor.
Definition:
backendinfo-rest-api.cpp:36
fawkes::LoggingAspect
Definition:
logging.h:38
BackendInfoRestApi::init
virtual void init()
Initialize the thread.
Definition:
backendinfo-rest-api.cpp:47
BackendInfoRestApi
Definition:
backendinfo-rest-api.h:33
WebviewRestArray< Backend >
BackendInfoRestApi::~BackendInfoRestApi
~BackendInfoRestApi()
Destructor.
Definition:
backendinfo-rest-api.cpp:42
fawkes::WebviewAspect
Definition:
webview.h:42
BackendInfoRestApi::finalize
virtual void finalize()
Finalize the thread.
Definition:
backendinfo-rest-api.cpp:87
fawkes::WebviewRestApi
Definition:
rest_api.h:225
fawkes::Thread
Definition:
thread.h:45
fawkes::ConfigurableAspect
Definition:
configurable.h:38
src
plugins
webview
backendinfo-rest-api
backendinfo-rest-api.h
Generated by
1.8.17