Documentation ¶
Overview ¶
Package ioutil implements I/O utility functions.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrShortRead = fmt.Errorf("ioutil: short read") ErrExpectEOF = fmt.Errorf("ioutil: expect EOF") )
Functions ¶
func NewExactReadCloser ¶
func NewExactReadCloser(rc io.ReadCloser, totalBytes int64) io.ReadCloser
NewExactReadCloser returns a ReadCloser that returns errors if the underlying reader does not read back exactly the requested number of bytes.
func NewLimitedBufferReader ¶
NewLimitedBufferReader returns a reader that reads from the given reader but limits the amount of data returned to at most n bytes.
Types ¶
Click to show internal directories.
Click to hide internal directories.