Add method File.Torrent

This commit is contained in:
Matt Joiner 2015-11-12 03:25:04 +11:00
parent 1a01ea87df
commit 55cae072f5
1 changed files with 4 additions and 0 deletions

View File

@ -15,6 +15,10 @@ type File struct {
fi metainfo.FileInfo fi metainfo.FileInfo
} }
func (f *File) Torrent() Torrent {
return f.t
}
// Data for this file begins this far into the torrent. // Data for this file begins this far into the torrent.
func (f *File) Offset() int64 { func (f *File) Offset() int64 {
return f.offset return f.offset