当前位置:首页 > 开发 > C# > 正文内容

C#解析Torrent获取磁力链

C#4年前 (2022-10-24)

NuGet添加 MonoTorrent

using MonoTorrent;
string file = @"D:\下载\5.torrent";
Torrent torrent = Torrent.Load(file);
Console.WriteLine("magnet:?xt=urn:btih:" + torrent.InfoHash.ToHex());
Console.ReadLine();
magnet:?xt=urn:btih:EA6380C88E8B58096B0100E6F0239800BF968848



转载请注明出处。

本文链接:http://www.pythonopen.com/?id=227

相关文章

CS0052 可访问性不一致: 字段类型“n1”的可访问性低于字段“n2”

问题CS0052 可访问性不一致: 字段类型“n1”的可访问性低于字段“n2”原因n1未使用publ...

C# 缩减代码量的一些方式

static void Main() { Thread thre...

C# System.IO.Path

System.IO.Path.GetExtension返回指定的路径字符串的扩展名。string&n...

C# Control防闪烁

SetStyle(ControlStyles.AllPaintingInWmPaint |...

C# i++和++i的区别

核心区别操作顺序            ...