ESP8266_swiss_army_board/src/app/WEBClient.h

25 lines
721 B
C++

#ifndef WEBCLIENT_H
#define WEBCLIENT_H
#include "WEBServer.h"
#include "TCPClient.h"
class WEBClient : public TCPClient
{
template <typename T>
friend class WEBServer;
public:
WEBClient(WiFiClient client, uint8_t id, uint16_t maxResourceBuffer = 255, uint16_t maxBodyBuffer = 255, uint16_t dataBufferSize = 511);
virtual ~WEBClient();
protected:
WEBServer<WEBClient>::WEBClientState _WEBClientState;
private:
WEBServer<WEBClient>::HttpRequestData _httpRequestData;
WEBServer<WEBClient>::HttpParserStatus _httpParserState;
uint64_t _fileSentBytes;
uint64_t _range; //Used to store the value of the range param for file downloading
void clearHttpRequestData();
};
#endif //WEBCLIENT_H