mirror of https://github.com/lumapu/ahoy.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
999 B
39 lines
999 B
2 years ago
|
#ifndef __WEB_API_H__
|
||
|
#define __WEB_API_H__
|
||
3 years ago
|
|
||
|
#include "dbg.h"
|
||
|
#include "ESPAsyncTCP.h"
|
||
|
#include "ESPAsyncWebServer.h"
|
||
|
#include "app.h"
|
||
|
|
||
|
|
||
|
class app;
|
||
|
|
||
2 years ago
|
class webApi {
|
||
3 years ago
|
public:
|
||
2 years ago
|
webApi(AsyncWebServer *srv, app *app, sysConfig_t *sysCfg, config_t *config, statistics_t *stat, char version[]);
|
||
3 years ago
|
|
||
|
void setup(void);
|
||
|
void loop(void);
|
||
|
|
||
|
private:
|
||
|
void onSystem(AsyncWebServerRequest *request);
|
||
2 years ago
|
void onStatistics(AsyncWebServerRequest *request);
|
||
3 years ago
|
void onInverterList(AsyncWebServerRequest *request);
|
||
|
void onMqtt(AsyncWebServerRequest *request);
|
||
2 years ago
|
void onNtp(AsyncWebServerRequest *request);
|
||
|
void onPinout(AsyncWebServerRequest *request);
|
||
|
void onRadio(AsyncWebServerRequest *request);
|
||
|
void onSerial(AsyncWebServerRequest *request);
|
||
3 years ago
|
|
||
|
AsyncWebServer *mSrv;
|
||
|
app *mApp;
|
||
|
|
||
|
config_t *mConfig;
|
||
|
sysConfig_t *mSysCfg;
|
||
2 years ago
|
statistics_t *mStat;
|
||
3 years ago
|
char *mVersion;
|
||
|
};
|
||
|
|
||
2 years ago
|
#endif /*__WEB_API_H__*/
|