pget

package
v0.5.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Getter

type Getter struct {
	Downloader download.Strategy
	Consumer   consumer.Consumer
	Options    Options
}

func (*Getter) DownloadFile

func (g *Getter) DownloadFile(ctx context.Context, url string, dest string) (int64, time.Duration, error)

func (*Getter) DownloadFiles added in v0.4.0

func (g *Getter) DownloadFiles(ctx context.Context, manifest Manifest) (int64, time.Duration, error)

type Manifest added in v0.4.0

type Manifest map[string][]ManifestEntry

A Manifest is a mapping from a base URI (consisting of scheme://authority) to a list of Manifest entries under that base URI. That is, the Manifest entries are grouped by remote server that we might connect to.

type ManifestEntry added in v0.4.0

type ManifestEntry struct {
	URL  string
	Dest string
}

type Options added in v0.5.0

type Options struct {
	MaxConcurrentFiles int
}

Directories

Path Synopsis
Package consistent implements consistent hashing for cache nodes.
Package consistent implements consistent hashing for cache nodes.

Jump to

Keyboard shortcuts

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