database.h 535 B

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef __SERVER_DATABASE_H__
  2. #define __SERVER_DATABASE_H__
  3. #include "common/def.h"
  4. #include <list>
  5. #include <std_lib/database/database.h>
  6. namespace database {
  7. void init();
  8. void resetDataBase();
  9. bool addMap(MapInfo info);
  10. bool updateMap(MapInfo info);
  11. bool updateConfig(std::string name, Json::Value config);
  12. bool updateShadowMap(std::string map_id, Points map);
  13. bool delMap(std::string map_id);
  14. MapInfo getMap(std::string id);
  15. std::string getConfig(std::string name);
  16. std::map<std::string, MapInfo> getMaps();
  17. }
  18. #endif