private static bool ReadDownUpLoadDat(string jsonPath, out DownUpLoadDat sDownUpLoadDat) { sDownUpLoadDat = new DownUpLoadDat(); try { if (!System.IO.File.Exists(jsonPath)) { return(false); } bool status; string jsonText; status = CaxPublic.ReadFileDataUTF8(jsonPath, out jsonText); if (!status) { return(false); } sDownUpLoadDat = JsonConvert.DeserializeObject <DownUpLoadDat>(jsonText); } catch (System.Exception ex) { return(false); } return(true); }
public static bool ReadDraftingConfig(string jsonPath, out DraftingConfig cDraftingConfig) { cDraftingConfig = new DraftingConfig(); try { if (!System.IO.File.Exists(jsonPath)) { return(false); } bool status; string jsonText; status = CaxPublic.ReadFileDataUTF8(jsonPath, out jsonText); if (!status) { return(false); } cDraftingConfig = JsonConvert.DeserializeObject <DraftingConfig>(jsonText); } catch (System.Exception ex) { return(false); } return(true); }