public static void readMisson() { try { string json = File.ReadAllText(Environment.CurrentDirectory + "/config/download.session"); List <DownloadSavedMisson> ms = new List <DownloadSavedMisson>(); ms = JsonConvert.DeserializeObject <List <DownloadSavedMisson> >(json); foreach (DownloadSavedMisson dobj in ms) { DownloadObject obj = new DownloadObject(dobj.aid, dobj.cid, dobj.quality, dobj.saveto, dobj.name, dobj.avname); DownloadQueue.AddDownload(obj); } } catch (Exception e) { //防止报错 } }