compressor

package
v0.0.0-...-ac4a226 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2021 License: MIT Imports: 4 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Compressor

type Compressor interface {
	Compress(data []byte) ([]byte, error)
	Decompress(data []byte) ([]byte, error)
}

Compressor is generic interface for compressor algorithms

type GzipComp

type GzipComp struct {
}

GzipComp is a compressor which uses the gzip

func (*GzipComp) Compress

func (l *GzipComp) Compress(data []byte) ([]byte, error)

Compress compresses the data based on the gzip

func (*GzipComp) Decompress

func (l *GzipComp) Decompress(data []byte) ([]byte, error)

Decompress decompresses the data which was compressed by gzip

type ZstdComp

type ZstdComp struct {
}

ZstdComp is a compressor which uses the zstandard

func (*ZstdComp) Compress

func (l *ZstdComp) Compress(data []byte) ([]byte, error)

Compress compresses the data based on the zstandard

func (*ZstdComp) Decompress

func (l *ZstdComp) Decompress(data []byte) ([]byte, error)

Decompress decompresses the data which was compressed by zstandard

Jump to

Keyboard shortcuts

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