Documentation ¶
Overview ¶
Package metainfo support for reading and writing torrent files.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Info ¶
type Info struct { PieceLength uint32 `bencode:"piece length" json:"piece_length"` Pieces []byte `bencode:"pieces" json:"pieces"` Private byte `bencode:"private" json:"private"` Name string `bencode:"name" json:"name"` Length int64 `bencode:"length" json:"length"` // Single File Mode Files []FileDict `bencode:"files" json:"files"` // Multiple File mode // Calculated fileds Hash [20]byte `bencode:"-" json:"-"` PieceHashes [][]byte `bencode:"-" json:"-"` TotalLength int64 `bencode:"-" json:"-"` NumPieces uint32 `bencode:"-" json:"-"` MultiFile bool `bencode:"-" json:"-"` InfoSize uint32 `bencode:"-" json:"-"` Bytes []byte `bencode:"-" json:"-"` }
Info contains information about torrent.
type MetaInfo ¶
type MetaInfo struct { Info *Info `bencode:"-"` RawInfo bencode.RawMessage `bencode:"info" json:"-"` Announce string `bencode:"announce"` AnnounceList [][]string `bencode:"announce-list"` CreationDate int64 `bencode:"creation date"` Comment string `bencode:"comment"` CreatedBy string `bencode:"created by"` Encoding string `bencode:"encoding"` }
MetaInfo file dictionary
func (*MetaInfo) GetTrackers ¶
Click to show internal directories.
Click to hide internal directories.