bzip2

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package bzip2 provides a reader and writer that propagate calls to Close.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadBytes

func ReadBytes(b []byte) io.Reader

ReadBytes returns a reader for reading bzip2-compressed bytes from an input slice.

Types

type ByteReadCloser

type ByteReadCloser interface {
	io.ReadCloser
	io.ByteReader
}

type Reader

type Reader struct {
	// contains filtered or unexported fields
}

func NewReader

func NewReader(r ByteReadCloser) *Reader

NewReader returns an io.Reader which decompresses bzip2 data from r. If r does not also implement io.ByteReader, the decompressor may read more data than necessary from r.

func ReadFile

func ReadFile(path string, bufferSize int) (*Reader, error)

ReadFile returns a reader for reading bytes from a bzip2-compressed file.

func (*Reader) Close

func (r *Reader) Close() error

func (*Reader) Read

func (r *Reader) Read(p []byte) (int, error)

Jump to

Keyboard shortcuts

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