Documentation ¶
Index ¶
Constants ¶
View Source
const ( TypeTorrent = "torrent" TypeHTTP = "http" )
Variables ¶
This section is empty.
Functions ¶
func NewTorrentDownloader ¶
func NewTorrentDownloader(repo *storage.MediaRepository) *torrentDownloader
Types ¶
type HttpDownloader ¶
type HttpDownloader struct {
// contains filtered or unexported fields
}
func NewHttpDownloader ¶
func NewHttpDownloader() *HttpDownloader
func (*HttpDownloader) Get ¶
func (d *HttpDownloader) Get(item media.SearchItem, url string, destination string) (Informer, error)
type Info ¶
type Info struct { Item media.SearchItem Filepath string TotalBytes int64 DownloadedBytes int64 IsDone bool Error error Url string }
func (*Info) ProgressBytes ¶
Progress returns the progress of the file from 0 to 1
Click to show internal directories.
Click to hide internal directories.