package zstd

  1. Overview
  2. Docs

Zstandard - fast lossless compression algorithm

exception Error of string
val version : unit -> int * int * int
val compress : level:int -> ?dict:string -> string -> string

dict optional pre-defined dictionary content (see dictBuilder)

val decompress : int -> ?dict:string -> string -> string

decompress orig_size ?dict s

orig_size specifies size of buffer for decompression (not less than original size of uncompressed s) dict must be identical to the one used during compression, otherwise uncompressed data will be corrupted.

val get_decompressed_size : string -> int