download

package
v1.0.7-alpha Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithClient

func WithClient(c *http.Client) optionFunc

func WithConcurrentRequest

func WithConcurrentRequest(num int) optionFunc

func WithDownloadMiddle

func WithDownloadMiddle(mid middle.Middleware) optionFunc

func WithDownloadRetry

func WithDownloadRetry(retry int) optionFunc

func WithLimiter

func WithLimiter(lim limiter.Limiter) optionFunc

func WithTimeout

func WithTimeout(timeout time.Duration) optionFunc

Types

type Download

type Download interface {
	middle.Middleware
	Do(req *stream.HttpRequest) (*stream.HttpResponse, error)
	Activate() bool

	Close() error
}

func ShortDownload

func ShortDownload(opt ...optionFunc) Download

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL