CConfigReader.h 652 B

12345678910111213141516171819202122232425262728293031323334
  1. #pragma once
  2. /*
  3. *这个类用来读取配置文件
  4. **/
  5. class CConfigReader
  6. {
  7. public:
  8. CConfigReader();
  9. ~CConfigReader();
  10. static void ReadConfigFile();
  11. static std::string getConfigValue(std::string key);
  12. static bool IsDebugMode();
  13. static std::string getPathPlanningHost();
  14. static std::string getMysqlHost();
  15. static std::string getMysqlPort();
  16. static std::string getMysqlUsername();
  17. static std::string getMysqlPassword();
  18. static std::string getDBName();
  19. static std::string getTaskQueue();
  20. static std::string getResultQueue();
  21. static int getDeliverymanMaxOrderNum();
  22. public:
  23. static std::map<string, string> m_mapConfigInfo;
  24. };