//从本地配置文件里加载
    public override bool loadFromConfig()
    {
        cachedlocal = persist.ReadFromLocalFileSystem(DataType.TIPS_CONFIG, AES_ENCRYPT) as NoticeLocal;
        if (cachedlocal == null)
        {
            cachedlocal = new NoticeLocal();
        }
        cachedlocal.mType = DataType.TIPS_CONFIG;

        return(true);
    }
    public static void load(DataPersistManager persist, out Dictionary <int, int> HttpDataNo)
    {
        HttpDataNo = new Dictionary <int, int>();

        HttpData_No db = persist.ReadFromLocalFileSystem(DataType.HTTP_COMPLETE, AES_ENCRYPT) as HttpData_No;

        if (db != null)
        {
            foreach (HttpDataNoElement element in db.httpNo)
            {
                HttpDataNo.Add(element.act, element.no);
            }
        }
    }
Beispiel #3
0
    public AccountConfigManager()
    {
        accInfo = null;
        persist = Core.DPM;

        accInfo = persist.ReadFromLocalFileSystem(DataType.ACCOUNT_CONFIG, AES_ENCRYPT) as AccountConfigData;
        if (accInfo == null)
        {
            accInfo = new AccountConfigData();
            accInfo.DefaultValue();
        }

        accInfo.mType = DataType.ACCOUNT_CONFIG;
    }
    public UserConfigManager()
    {
        userInfo = null;
        persist  = Core.DPM;

        userInfo = persist.ReadFromLocalFileSystem(DataType.USER_CONFIG, AES_ENCRYPT) as UserConfigData;
        if (userInfo == null)
        {
            userInfo = new UserConfigData();
            userInfo.DefaultValue();
        }

        userInfo.mType = DataType.USER_CONFIG;
    }