Documentation ¶
Index ¶
- func Pipe(reader Reader, writer Writer) error
- type AdaptiveReader
- type AdaptiveWriter
- type BufferedReader
- type BufferedWriter
- func (this *BufferedWriter) Cached() bool
- func (this *BufferedWriter) Flush() error
- func (this *BufferedWriter) FlushWithoutLock() error
- func (this *BufferedWriter) ReadFrom(reader io.Reader) (int64, error)
- func (this *BufferedWriter) Release()
- func (this *BufferedWriter) SetCached(cached bool)
- func (this *BufferedWriter) Write(b []byte) (int, error)
- type ChainWriter
- type ChanReader
- type Reader
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AdaptiveReader ¶
type AdaptiveReader struct {
// contains filtered or unexported fields
}
AdaptiveReader is a Reader that adjusts its reading speed automatically.
func NewAdaptiveReader ¶
func NewAdaptiveReader(reader io.Reader) *AdaptiveReader
NewAdaptiveReader creates a new AdaptiveReader. The AdaptiveReader instance doesn't take the ownership of reader.
func (*AdaptiveReader) Read ¶
func (this *AdaptiveReader) Read() (*alloc.Buffer, error)
Read implements Reader.Read().
func (*AdaptiveReader) Release ¶
func (this *AdaptiveReader) Release()
type AdaptiveWriter ¶
type AdaptiveWriter struct {
// contains filtered or unexported fields
}
AdaptiveWriter is a Writer that writes alloc.Buffer into underlying writer.
func NewAdaptiveWriter ¶
func NewAdaptiveWriter(writer io.Writer) *AdaptiveWriter
NewAdaptiveWriter creates a new AdaptiveWriter.
func (*AdaptiveWriter) Release ¶
func (this *AdaptiveWriter) Release()
type BufferedReader ¶
func NewBufferedReader ¶
func NewBufferedReader(rawReader io.Reader) *BufferedReader
func (*BufferedReader) Cached ¶
func (this *BufferedReader) Cached() bool
func (*BufferedReader) Release ¶
func (this *BufferedReader) Release()
func (*BufferedReader) SetCached ¶
func (this *BufferedReader) SetCached(cached bool)
type BufferedWriter ¶
func NewBufferedWriter ¶
func NewBufferedWriter(rawWriter io.Writer) *BufferedWriter
func (*BufferedWriter) Cached ¶
func (this *BufferedWriter) Cached() bool
func (*BufferedWriter) Flush ¶
func (this *BufferedWriter) Flush() error
func (*BufferedWriter) FlushWithoutLock ¶ added in v1.18.1
func (this *BufferedWriter) FlushWithoutLock() error
func (*BufferedWriter) ReadFrom ¶ added in v1.18.1
func (this *BufferedWriter) ReadFrom(reader io.Reader) (int64, error)
func (*BufferedWriter) Release ¶
func (this *BufferedWriter) Release()
func (*BufferedWriter) SetCached ¶
func (this *BufferedWriter) SetCached(cached bool)
type ChainWriter ¶ added in v1.18.1
func NewChainWriter ¶ added in v1.18.1
func NewChainWriter(writer Writer) *ChainWriter
func (*ChainWriter) Release ¶ added in v1.18.1
func (this *ChainWriter) Release()
type ChanReader ¶ added in v1.18.1
func NewChanReader ¶ added in v1.18.1
func NewChanReader(stream Reader) *ChanReader
func (*ChanReader) Fill ¶ added in v1.18.1
func (this *ChanReader) Fill()
Private: Visible for testing.
func (*ChanReader) Release ¶ added in v1.18.1
func (this *ChanReader) Release()
Click to show internal directories.
Click to hide internal directories.