public bool Prepare() { var query = from el in _context.SoftPosts where el.Id == 85 || el.Id == 132 || el.Id == 311 select el; IList <SoftPost> lst = query.ToList(); var parser = new BencodeParser(); Torrent file0 = parser.Parse <Torrent>(lst[0].TorrentFile); Torrent file1 = parser.Parse <Torrent>(lst[1].TorrentFile); Torrent file2 = parser.Parse <Torrent>(lst[2].TorrentFile); Torrent softFirefox = parser.Parse <Torrent>(@"F:\VS Projects\[Torrent-Soft.Net]_Firefox Browser 81.0.1.torrent"); Torrent nnmFirefox = parser.Parse <Torrent>(@"F:\VS Projects\nnm club firefox.torrent"); Torrent rutorFirefox = parser.Parse <Torrent>(@"F:\VS Projects\rutor firefox.torrent"); var trackers = softFirefox.Trackers.Union(rutorFirefox.Trackers); softFirefox.Trackers = trackers.ToList(); softFirefox.EncodeTo(@"F:\VS Projects\[Custom]rutor and soft firefox.torrent"); return(true); }
private void CreateTorrentBackup() { torrent.EncodeTo(torrentCopy); torrentCopy.Close(); }