28 lines
556 B
C++
28 lines
556 B
C++
#pragma once
|
|
|
|
class JsonDataMgr : public a8::Singleton<JsonDataMgr>
|
|
{
|
|
private:
|
|
JsonDataMgr() {};
|
|
friend class a8::Singleton<JsonDataMgr>;
|
|
|
|
public:
|
|
void Init();
|
|
void UnInit();
|
|
|
|
std::shared_ptr<a8::XObject> GetConf();
|
|
std::shared_ptr<a8::XObject> GetMasterServerClusterConf();
|
|
|
|
std::string ip;
|
|
int listen_port = 0;
|
|
int channel = 0;
|
|
std::string server_info;
|
|
|
|
void Reload();
|
|
|
|
private:
|
|
std::string work_path_ = "../config";
|
|
a8::XObject gameserver_cluster_json_;
|
|
a8::XObject masterserver_cluster_json_;
|
|
};
|