Files
IoTManager/include/classes/SendJson.h

32 lines
498 B
C
Raw Normal View History

#pragma once
#include "Global.h"
2022-01-20 13:36:00 +01:00
#ifdef QUEUE_FROM_STR
#include "classes/QueueFromStruct.h"
class SendJson;
2021-12-30 23:58:56 +01:00
class SendJson {
public:
SendJson();
~SendJson();
2022-01-20 13:36:00 +01:00
void addFileToQueue(String path, uint8_t num);
void loop();
2021-12-30 23:58:56 +01:00
void sendWs(String& jsonArrayElement);
void sendMqtt(String& jsonArrayElement);
2022-01-20 13:36:00 +01:00
QueueItems myItem;
private:
File file;
String _path;
2022-01-20 13:36:00 +01:00
uint8_t _num;
bool sendingInProgress = false;
};
2022-01-20 13:36:00 +01:00
extern SendJson* sendJsonFiles;
#endif