MCPcopy Index your code
hub / github.com/klauspost/compress / EncodeNoHist

Method EncodeNoHist

zstd/enc_best.go:471–474  ·  view source on GitHub ↗

EncodeNoHist will encode a block with no history and no following blocks. Most notable difference is that src will not be copied for history and we do not need to check for max match length.

(blk *blockEnc, src []byte)

Source from the content-addressed store, hash-verified

469// Most notable difference is that src will not be copied for history and
470// we do not need to check for max match length.
471func (e *bestFastEncoder) EncodeNoHist(blk *blockEnc, src []byte) {
472 e.ensureHist(len(src))
473 e.Encode(blk, src)
474}
475
476// Reset will reset and set a dictionary if not nil
477func (e *bestFastEncoder) Reset(d *dict, singleBlock bool) {

Callers

nothing calls this directly

Calls 2

EncodeMethod · 0.95
ensureHistMethod · 0.80

Tested by

no test coverage detected