public Stat(string path, bool withText = false) { Dir = Path.GetDirectoryName(path); StreamReader reader = new StreamReader(path); string json = reader.ReadToEnd(); reader.Close(); Info = UseStatJson.GetStat(json); Interval = new Interval(Info.inter, Dir, withText); }
public void ChangeJson(string json, bool withText = false) { Info = UseStatJson.GetStat(json); Interval = new Interval(Info.inter, Dir, withText); }
public Stat(string json, string dir, bool withText = false) { Dir = dir; Info = UseStatJson.GetStat(json); Interval = new Interval(Info.inter, dir, withText); }
public static string GetJson(StatJson stat) => JsonConvert.SerializeObject(stat);