service

package
v0.5.5 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2019 License: LGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DownloadByChunks

func DownloadByChunks(url string, chunkSize uint64, writer io.WriteCloser) error

func FetchContentLength added in v0.4.6

func FetchContentLength(url string) (int64, error)

Types

type Item

type Item struct {
	Meta             map[string]string
	DefaultName      string
	AvailableOptions map[string]([]string)
	DefaultOptions   map[string]string
}

type Service

type Service interface {
	IsValidTarget(target string) bool
	FetchItems(target string) (ServiceIterator, error)
	Download(meta, options map[string]string) (io.Reader, error)
}

type ServiceIterator

type ServiceIterator interface {
	Next() ([]Item, error)
	HasEnded() bool
}

type Sized

type Sized interface {
	Size() uint64
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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