ParseTorrent (ParseTorrent v0.3.2) View Source
A module for convenient .torrent parsing.
Link to this section Summary
Functions
Parses a torrent binary and returns a map.
Parses a torrent binary and returns a map. Will raise if binary is invalid.
Link to this section Functions
Specs
Parses a torrent binary and returns a map.
Examples
data = File.read!("test/torrents/leaves.torrent")
{:ok, torrent_map} = ParseTorrent.parse(data)
Specs
Parses a torrent binary and returns a map. Will raise if binary is invalid.
Examples
data = File.read!("test/torrents/leaves.torrent")
torrent_map = ParseTorrent.parse!(data)