Documentation ¶
Index ¶
- Constants
- func CheckMultipart(urls string) (bool, error)
- func GetSize(urls string) (int64, error)
- type DownloadProgress
- type Downloader
- type FileInfo
- type PartialDownloader
- func (pd *PartialDownloader) AfterStop() error
- func (pd *PartialDownloader) AfterStopDownload() error
- func (pd *PartialDownloader) BeforeDownload() error
- func (pd *PartialDownloader) BeforeRun() error
- func (pd *PartialDownloader) DoWork() (bool, error)
- func (pd *PartialDownloader) DownloadSergment() (bool, error)
- func (pd PartialDownloader) GetProgress() interface{}
Constants ¶
View Source
const FlushDiskSize = 1024 * 1024
Variables ¶
This section is empty.
Functions ¶
func CheckMultipart ¶
Types ¶
type DownloadProgress ¶
type Downloader ¶
type Downloader struct { Fi FileInfo // contains filtered or unexported fields }
func CreateDownloader ¶
func CreateDownloader(url string, fp string, seg int64) (dl *Downloader, err error)
func RestoreDownloader ¶
func RestoreDownloader(url string, fp string, dp []DownloadProgress) (dl *Downloader, err error)
func (*Downloader) GetProgress ¶
func (dl *Downloader) GetProgress() []DownloadProgress
func (*Downloader) StartAll ¶
func (dl *Downloader) StartAll() []error
func (*Downloader) StopAll ¶
func (dl *Downloader) StopAll() []error
type PartialDownloader ¶
type PartialDownloader struct {
// contains filtered or unexported fields
}
func CreatePartialDownloader ¶
func (*PartialDownloader) AfterStop ¶
func (pd *PartialDownloader) AfterStop() error
func (*PartialDownloader) AfterStopDownload ¶
func (pd *PartialDownloader) AfterStopDownload() error
func (*PartialDownloader) BeforeDownload ¶
func (pd *PartialDownloader) BeforeDownload() error
func (*PartialDownloader) BeforeRun ¶
func (pd *PartialDownloader) BeforeRun() error
func (*PartialDownloader) DoWork ¶
func (pd *PartialDownloader) DoWork() (bool, error)
func (*PartialDownloader) DownloadSergment ¶
func (pd *PartialDownloader) DownloadSergment() (bool, error)
func (PartialDownloader) GetProgress ¶
func (pd PartialDownloader) GetProgress() interface{}
Click to show internal directories.
Click to hide internal directories.