fastweb.h 688 B

12345678910111213141516171819202122232425262728
  1. #pragma once
  2. #include "define.h"
  3. #include "base/error.h"
  4. #include "base/singleton.hpp"
  5. #include "net/http_center.h"
  6. #include "core/subscribemanager.h"
  7. #include "core/interceptormanager.h"
  8. class fastweb:public ylib::error_base,public ylib::singleton<fastweb> {
  9. public:
  10. fastweb();
  11. bool start();
  12. void stop();
  13. private:
  14. /// <summary>
  15. /// 初始化执行脚本
  16. /// </summary>
  17. /// <returns></returns>
  18. bool initialization_script();
  19. private:
  20. // 初始化脚本虚拟机
  21. luastate* m_state_init = nullptr;
  22. // 网站服务核心
  23. network::http::center *m_center = nullptr;
  24. // 订阅管理器
  25. subscribe_manager m_subscribe;
  26. // 拦截器管理器
  27. interceptor_manager m_interceptor;
  28. };