lz4

package
v0.0.0-...-77e5a9a Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2023 License: BSD-2-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Score

func Score(m pack.AbsoluteMatch) int

Types

type BestSpeed

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

BestSpeed is an implementation of the MatchFinder interface that is comparable to level 1 (BestSpeed) in compress/flate.

func (*BestSpeed) FindMatches

func (q *BestSpeed) FindMatches(dst []pack.Match, src []byte) []pack.Match

FindMatches looks for matches in src, appends them to dst, and returns dst.

func (*BestSpeed) Reset

func (q *BestSpeed) Reset()

type BlockEncoder

type BlockEncoder struct{}

A BlockEncoder implements the pack.Encoder interface, writing in the LZ4 block format.

func (BlockEncoder) Encode

func (BlockEncoder) Encode(dst []byte, src []byte, matches []pack.Match, lastBlock bool) []byte

func (BlockEncoder) Reset

func (BlockEncoder) Reset()

type FrameEncoder

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

A FrameEncoder implements the pack.Encoder interface, writing in the LZ4 frame format.

func (*FrameEncoder) Encode

func (f *FrameEncoder) Encode(dst []byte, src []byte, matches []pack.Match, lastBlock bool) []byte

func (*FrameEncoder) Reset

func (f *FrameEncoder) Reset()

Jump to

Keyboard shortcuts

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