betto_zstd library

Zstd compression and decompression for Dart.

This library provides a high-level API for using the Zstandard (Zstd) compression algorithm in Dart applications. It supports synchronous compression and decompression on native platforms (via FFI) and on the web (via an Emscripten-compiled WASM module).

On web, call ZstdSimple.init and await it before using any ZstdSimple instance. On native platforms ZstdSimple.init is a no-op.

Classes

ZstdSimple
Stub implementation of ZstdSimple for unsupported platforms.

Functions

maxCLevel() int
Returns the maximum compression level.
minCLevel() int
Returns the minimum compression level.

Exceptions / Errors

ZstdException
Thrown when the Zstd library reports a compression or decompression error, or when the frame header is invalid or missing content size information.