#ifndef A8_BASE_HTTPSESSION_H #define A8_BASE_HTTPSESSION_H #include namespace a8 { typedef std::map HTTPRequest; class BaseHttpSession : public TcpSession { protected: virtual void OnRawHttpGet(const std::string& url, const std::string& querystr, std::string& response); virtual void OnHttpGet(const std::string& url, a8::HTTPRequest& request, std::string& response); void ProcessHttpHandShake(char* buf, int& offset, unsigned int buflen); protected: virtual void Reset() override; virtual void DecodePacket(char*, int& offset, unsigned int) override; protected: bool handled_ = false; }; } #endif