lz4DecompressBlockWithDict

private fnsize_t lz4DecompressBlockWithDict(const(ubyte)[] src, ubyte[] dst, const(ubyte)[] dict)

Decompress a single LZ4 block with dictionary support.

When a dictionary is provided, match offsets that exceed the current output position reference data in the dictionary. The dictionary is treated as data that logically precedes the decompressed output.

Parameters

srcLZ4 block to decode.
dstDestination buffer; must be large enough to hold the decompressed data.
dictOptional dictionary data (may be null or empty).

Returns

Number of bytes written to dst.

Throws

- CompressionError with ErrorCode.TRUNCATED if the input block

ends prematurely.

  • CompressionError with ErrorCode.DATA_ERROR if an invalid

offset or other structural inconsistency is encountered.