testreader

package
Version: v1.21.0 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUser = errors.New("error set by user")

ErrUser is returned by ChunkReader when the user requests an error.

Functions

func ChunkReader added in v1.0.1

func ChunkReader() (chan<- []byte, io.Reader)

ChunkReader returns a reader that returns chunks written to the control channel. The caller should write byte chunks to return to the channel, or write nil if they want the Reader to return an error. The control channel should be closed to signal EOF.

func Looper

func Looper(bs []byte) io.Reader

Looper returns a reader that will return the bytes in bs as if it was a circular buffer.

Types

This section is empty.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL