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.

42 lines
1.1 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef __PROTOCOL_PROXY_HTTP_STREAM_HEADER__
  2. #define __PROTOCOL_PROXY_HTTP_STREAM_HEADER__
  3. #include "../../components/base/basicSettingsProvider.h"
  4. #include "../../components/base/basicTransport.h"
  5. #include "../net/clientPort.h"
  6. #include "../net/netClientHandler.h"
  7. /**
  8. * TODO: Add class description
  9. *
  10. * @author gagua
  11. */
  12. class protocolProxyStreamHTTP : public networkClientHandler
  13. {
  14. private:
  15. bool m_bStreamingActive;
  16. CSTR m_pRequestedURL;
  17. CSTR m_pRequestedHost;
  18. int m_pRequestedPort;
  19. protected:
  20. basicLogCollection * m_pLog;
  21. clientPort * m_oDataTransport;
  22. virtual int packetChecker(unsigned char * Buffer, size_t BufferSize);
  23. virtual protocolPackage * packetExtractor(unsigned char * Buffer, size_t BufferSize);
  24. virtual bool packetHandler(protocolPackage * Package);
  25. public:
  26. // Constructor
  27. explicit protocolProxyStreamHTTP(SOCKET SocketFD, config_setting_t * Settings = NULL);
  28. // ToDo: change Serial to BaseClass of some kind of socket
  29. // protocolHTTP( clientPort *SocketTransport, config_setting_t *Settings = NULL );
  30. // Destructor
  31. virtual ~protocolProxyStreamHTTP();
  32. };
  33. #endif