oobmultipartreader

package module
v0.0.0-...-6d2ab69 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2017 License: MIT Imports: 6 Imported by: 0

README

OOBMultiPartReader Travis Codecov go-report

Use multipart without buffering, directly "out of band".

go get github.com/Eun/oobmultipartreader

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Field

type Field struct {
	Header textproto.MIMEHeader
	Reader io.Reader
}

Field is a Multipart Fragment that defines would be written in the response

type NextField

type NextField func(reader *OOBMultipartReader, field *Field) (err error)

NextField is a function that returns the next Field

type NoNextFieldError

type NoNextFieldError struct{}

NoNextFieldError is an error that is triggered as soon as the NextField in OOBMultipartReader is nil

func (NoNextFieldError) Error

func (NoNextFieldError) Error() string

type OOBMultipartReader

type OOBMultipartReader struct {
	Boundary      string
	NextField     NextField
	WrittenFields int
	// contains filtered or unexported fields
}

OOBMultipartReader is a io.Reader that generates a multipart stream out of multiple other readers

func (*OOBMultipartReader) Read

func (reader *OOBMultipartReader) Read(p []byte) (int, error)

Jump to

Keyboard shortcuts

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