Documentation
¶
Overview ¶
Package stackless saves stack space for high number of concurrently running goroutines, which use writers from compress/* packages.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NewWriterFunc ¶
NewWriterFunc must return new writer that will be wrapped into stackless writer.
type Writer ¶
type Writer interface { Write(p []byte) (int, error) Flush() error Close() error Reset(w io.Writer) }
Writer is an interface stackless writer must conform to.
The interface contains common subset for Writers from compress/* packages.
func NewWriter ¶
func NewWriter(dstW io.Writer, newWriter NewWriterFunc) Writer
NewWriter creates a stackless writer around a writer returned from newWriter.
The returned writer writes data to dstW.
Writers that use a lot of stack space may be wrapped into stackless writer, thus saving stack space for high number of concurrently running goroutines.
Click to show internal directories.
Click to hide internal directories.