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.

26 lines
878 B

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef __SERVLET_WEB_SOCKET_HEADER__
  2. #define __SERVLET_WEB_SOCKET_HEADER__
  3. #include "../../components/base/basicDualThread.h"
  4. #include "servletChannelWS.h"
  5. #include "servletClientHandlerWS.h"
  6. class servletWS: public basicDualThread{
  7. private:
  8. basicLogCollection * m_pLog;
  9. int m_nSocketDescriptor;
  10. uint16_t m_nListenPort;
  11. vectorChannelsWS m_vChannels;
  12. vectorClientHandlerWS m_vWebClients;
  13. public:
  14. explicit servletWS( uint16_t ListenPort = 8081 );
  15. virtual ~servletWS();
  16. bool create( uint16_t ListenPort = 8081 );
  17. virtual void m_fThreadAProc( void ); // Listener
  18. virtual void m_fThreadBProc( void ); // Worker
  19. bool attachChannel( CSTR MediaURI, bool LocalDevice );
  20. };
  21. #endif