Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

PrevUpHomeNext

zlib::z_params

Deflate codec parameters.

Synopsis

Defined in header <boost/beast/zlib/zlib.hpp>

struct z_params
Data Members

Name

Description

avail_in

The number of bytes of input available at next_in.

avail_out

The remaining bytes of space at next_out.

data_type

Best guess about the data type: binary or text.

next_in

A pointer to the next input byte.

next_out

A pointer to the next output byte.

total_in

The total number of input bytes read so far.

total_out

The total number of bytes output so far.

Description

Objects of this type are filled in by callers and provided to the deflate codec to define the input and output areas for the next compress or decompress operation.

The application must update next_in and avail_in when avail_in has dropped to zero. It must update next_out and avail_out when avail_out has dropped to zero. The application must initialize zalloc, zfree and opaque before calling the init function. All other fields are set by the compression library and must not be updated by the application.

The fields total_in and total_out can be used for statistics or progress reports. After compression, total_in holds the total size of the uncompressed data and may be saved for use in the decompressor (particularly if the decompressor wants to decompress everything in a single step).


PrevUpHomeNext