Documentation
¶
Index ¶
- func AddCloser(reader io.ReadCloser, closer io.Closer, msg ...string) io.ReadCloserdeprecated
- func AddReaderCloser(reader io.Reader, closer io.Closer, msg ...interface{}) io.ReadCloser
- func AddWriterCloser(writer io.Writer, closer io.Closer, msg ...interface{}) io.WriteCloser
- func ReadCloser(r io.Reader) io.ReadCloser
- func VerifyingReader(r io.ReadCloser, digest digest.Digest) io.ReadCloser
- func VerifyingReaderWithHash(r io.ReadCloser, hash crypto.Hash, digest string) io.ReadCloser
- func WriteCloser(w io.Writer) io.WriteCloser
- type CountingReader
- type CountingWriter
- type DigestReader
- type DigestWriter
- type DupReadCloser
- type NopCloser
- type NopWriter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddCloser
deprecated
func AddCloser(reader io.ReadCloser, closer io.Closer, msg ...string) io.ReadCloser
Deprecated: use AddReaderCloser .
func AddReaderCloser ¶
func AddWriterCloser ¶
func ReadCloser ¶
func ReadCloser(r io.Reader) io.ReadCloser
func VerifyingReader ¶
func VerifyingReader(r io.ReadCloser, digest digest.Digest) io.ReadCloser
func VerifyingReaderWithHash ¶
func VerifyingReaderWithHash(r io.ReadCloser, hash crypto.Hash, digest string) io.ReadCloser
func WriteCloser ¶
func WriteCloser(w io.Writer) io.WriteCloser
Types ¶
type CountingReader ¶
type CountingReader struct {
// contains filtered or unexported fields
}
func NewCountingReader ¶
func NewCountingReader(r io.Reader) *CountingReader
func (*CountingReader) Size ¶
func (r *CountingReader) Size() int64
type CountingWriter ¶
type CountingWriter struct {
// contains filtered or unexported fields
}
func NewCountingWriter ¶
func NewCountingWriter(w io.Writer) *CountingWriter
func (*CountingWriter) Size ¶
func (w *CountingWriter) Size() int64
type DigestReader ¶
type DigestReader struct {
// contains filtered or unexported fields
}
func NewDefaultDigestReader ¶
func NewDefaultDigestReader(r io.Reader) *DigestReader
func NewDigestReaderWith ¶
func NewDigestReaderWith(algorithm digest.Algorithm, r io.Reader) *DigestReader
func NewDigestReaderWithHash ¶
func NewDigestReaderWithHash(hash crypto.Hash, r io.Reader) *DigestReader
func (*DigestReader) Digest ¶
func (r *DigestReader) Digest() digest.Digest
func (*DigestReader) Size ¶
func (r *DigestReader) Size() int64
type DigestWriter ¶
type DigestWriter struct {
// contains filtered or unexported fields
}
func NewDefaultDigestWriter ¶
func NewDefaultDigestWriter(w io.WriteCloser) *DigestWriter
func NewDigestWriterWith ¶
func NewDigestWriterWith(algorithm digest.Algorithm, w io.WriteCloser) *DigestWriter
func (*DigestWriter) Digest ¶
func (r *DigestWriter) Digest() digest.Digest
func (*DigestWriter) Size ¶
func (r *DigestWriter) Size() int64
type DupReadCloser ¶
type DupReadCloser interface { io.ReadCloser Dup() (DupReadCloser, error) }
func NewDupReadCloser ¶
func NewDupReadCloser(rc io.ReadCloser, errs ...error) (DupReadCloser, error)
NewDupReadCloser provides a reader which can be duplicated. Duplicated means, that a new separately closeable reader is provided. The original reader is closed with the close of the last provided reader view. The passed reader must never be explicitly closed. It is closed with the last provided DupReadCloser. If called for a DupReadCloser, just a new view is provided. If called for an already closed reader, read calls will provide the behaviour of the passed reader. Close will succeed until the view is closed, which will provide the behaviour of the passed reader.
Click to show internal directories.
Click to hide internal directories.