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

C#解析Torrent获取磁力链

C#3年前 (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

相关文章

C# 热键

API     /// <summary>...

在 C# 中实现类似于 Windows 资源管理器的“名称”排序方式

要在 C# 中实现类似于 Windows 资源管理器的“名称”排序方式,你需要考虑以下几点:1. 不...

C# BackgroundWorker

1.概述BackgroundWorker是一个在 WinForms 应用程序中用于简化在后台线程执行...

C# Winform 拖放文件

private void Form1_Load(object send...

C# 类接口

定义接口是一种抽象类型,它定义了一组方法签名(方法名称、参数列表和返回类型),但没有方法体。接口用于...

C# MemoryStream转为Image

        //...