#pragma once
#include <map>
struct M_NoticeData
{
	//key
	int mID;
	//图片
	std::string mIcon;
	//标题
	std::string mName;
	//内容
	std::string mContent;
	//显示排序
	int mIndex;
	//开始时间
	std::string mStartTime;
	//结束时间 
	std::string mEndTime;
};

class M_Notice
{
public:
private:
	static std::auto_ptr<M_Notice> msSingleton;
public:
	int GetCount();
	const M_NoticeData* GetData(int ID);
	const std::map<int, M_NoticeData>& GetMapData();
	void Load();
	void LoadLua();
	void Reload();
	static M_Notice* GetSingleton();
	static void Release();
private:
	std::map<int, M_NoticeData> mMapData;
};
