tar

package
v0.0.0-...-5564391 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2018 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Reader

type Reader struct {
	tar.Reader
}

Reader provides sequential access to the contents of a tar archive.

func NewReader

func NewReader(r io.Reader) *Reader

NewReader creates a new Reader reading from r.

func (*Reader) NextFile

func (r *Reader) NextFile() (name string, err error)

NextFile advances to the next file in the tar archive.

type Writer

type Writer struct {
	tar.Writer
	// contains filtered or unexported fields
}

Writer provides sequential writing of a tar archive in POSIX.1 format.

func NewWriteMultiCloser

func NewWriteMultiCloser(w io.WriteCloser, closers ...io.Closer) *Writer

NewWriteMultiCloser creates a new Writer writing to w that also closes all closers in order on close.

func NewWriter

func NewWriter(w io.Writer) *Writer

NewWriter creates a new Writer writing to w.

func (*Writer) Close

func (w *Writer) Close() error

Close closes the tar archive and all other closers, flushing any unwritten data to the underlying writer.

func (*Writer) NextFile

func (w *Writer) NextFile(name string, fi os.FileInfo) error

NextFile computes and writes a header and prepares to accept the file's contents.

Jump to

Keyboard shortcuts

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