Go語言實現的BitTorrent客戶端包和工具類:torrent
這個項目用Go語言實現了BitTorrent相關的包和命令行工具。
還支持加密協議, DHT, PEX, uTP, 和各種擴展。還提供了幾個存儲后端, blob, file, mmap。You can use the provided binaries in./cmd, or usetorrentas a library for your own applications.
package torrent
import "github.com/anacrolix/torrent"Package torrent implements a torrent client.
示例:
c, _ := NewClient() t, _, c.AddMagnet("magnet:?xt=urn:btih:ZOCMZQIPFFW7OLLMIC5HUB6BPCSDEOQU") t.DownloadAll() c.WaitAll() log.Print("erhmahgerd, torrent downloaded") c.Close()
本文由用戶 fn67 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!