streaming

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultRangeSize = int64(5 * bytefmt.MEGABYTE)

Variables

This section is empty.

Functions

func NextRange

func NextRange(currentTotal int64, maxRangeSize int64, contentLength int64) (start, end int64, size int)

func ReadExactly

func ReadExactly(in io.Reader, buffer []byte) (err error)

ReadExactly reads exactly the number of bytes to fill the specified buffer, otherwise returning an error.

func ValidAbsURL

func ValidAbsURL(urlStr string) (*url.URL, error)

ValidAbsURL parses the specified URL string, returning an error if the URL cannot be parsed, or is not absolute (i.e., does not have a scheme)

func WriteExactly

func WriteExactly(out io.Writer, data []byte) (err error)

WriteExactly writes exactly the number of bytes found in the specified buffer, otherwise returning an error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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