infra: Index | Files

package limitwriter

import ""


Package Files


type LimitWriter Uses

type LimitWriter struct {
    // contains filtered or unexported fields

LimitWriter implements io.Writer and writes the data to an io.Writer, but limits the total bytes written to it, dropping the remaining bytes on the floor.

func New Uses

func New(dst io.Writer, limit int) *LimitWriter

New create a new LimitWriter that accepts at most 'limit' bytes.

func (*LimitWriter) Write Uses

func (l *LimitWriter) Write(p []byte) (int, error)

Package limitwriter imports 1 packages (graph) and is imported by 3 packages. Updated 2018-05-24. Refresh now. Tools for package owners.