ZLib
Give access to the popular ZLib compression library, used in several file
formats such as ZIP and PNG.
'dstream deflate_init(level : int) Open a compression stream with the given level of compression
{ done => bool, read => int, write => int} deflate_buffer('dstream, src : string, srcpos : int, dst : string, dstpos : int)
void deflate_end('dstream) Close a compression stream
'istream inflate_init(window_size : int?) Open a decompression stream
{ done => bool, read => int, write => int} inflate_buffer('istream, src : string, srcpos : int, dst : string, dstpos : int)
void inflate_end('istream) Close a decompression stream
void set_flush_mode('stream, string) Change the flush mode ("NO","SYNC","FULL","FINISH","BLOCK")
'int32 get_adler32('stream) Returns the adler32 value of the stream
'int32 update_adler32(adler : 'int32, string, pos : int, len : int) Update an adler32 value with a substring
'int32 update_crc32(crc : 'int32, string, pos : int, len : int) Update a CRC32 value with a substring
int deflate_bound('dstream, n : int) Return the maximum buffer size needed to write n bytes