#ifndef GERMANAIRLINESVA_GACONNECTOR_WEBSOCKET_WEBSOCKET_H #define GERMANAIRLINESVA_GACONNECTOR_WEBSOCKET_WEBSOCKET_H #define BUFSIZE 1024 #define MD5LEN 16 #include #include #include #include "types.h" #include "util.hpp" #include #include #include #include #include namespace germanairlinesva { namespace gaconnector { namespace websocket { class Websocket { private: char lastPath[513] = ""; char lastHash[2 * MD5LEN + 1] = ""; ix::WebSocket *webSocket = nullptr; std::string host; std::string user; std::function toLog; public: Websocket(std::string host, std::string user, std::function toLog); ~Websocket(); void onClientMessageCallback(const ix::WebSocketMessagePtr &msg); void sendData(data &d); }; } // namespace websocket } // namespace gaconnector } // namespace germanairlinesva #endif