public static WeChatConfig GetWeChatConfig() { var myAppPath = MyAppPath.Resolve(); var appData = myAppPath.AppData; var typeFilePathHelper = TypeFilePathHelper.Resolve(); var filePath = typeFilePathHelper.AutoGuessTypeFilePath(appData, typeof(WeChatConfig)); var fileDbHelper = FileDbHelper.Resolve(); var weChatConfigs = fileDbHelper.Read <WeChatConfig>(filePath); return(weChatConfigs.FirstOrDefault()); }
public InitDataContext() { FileDbHelper = AppData.FileDbHelper.Resolve(); TypeFilePathHelper = AppData.TypeFilePathHelper.Resolve(); AppPath = MyAppPath.Resolve(); }