compression

package
v0.0.0-...-1c6d3df Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Compressor

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

Compressor is an interface to be implemented by types that support reading and writing of compressed data of a specific format

type LZ4Compressor

type LZ4Compressor struct{}

LZ4Compressor uses the lz4 algorithm to convert byte arrays

func (*LZ4Compressor) Compress

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

Compress takes an input byte array and compresses it using the LZ4 algorithm

func (*LZ4Compressor) Uncompress

func (l *LZ4Compressor) Uncompress(data []byte) ([]byte, error)

Uncompress takes an input byte array and uncompresses it using the LZ4 algorithm

Jump to

Keyboard shortcuts

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