tiny.deflate.Format
Defined in tiny.deflate.
The three wrappings that decompress accepts around DEFLATE data, for a caller to pass one tag to decompress to say which wrapper surrounds the compressed data.
API (3)
Fields and members
Public fields and members.
Source
Source: lib/deflate/src/model.zig:4
zig
/// The three wrappings that `decompress` accepts around DEFLATE data, for a caller to pass one tag/// to `decompress` to say which wrapper surrounds the compressed data. The caller picks the tag/// from the file format it reads, for example `zlib` for a PDF content stream.pub const Format = enum { /// A raw stream, with no header and no trailer. The stream carries no checksum, so only the /// structure of the stream itself is checked. The input is DEFLATE data alone, a run of /// compressed blocks in the form RFC 1951 defines. raw, /// The zlib container of RFC 1950. The layout is a two-byte header that names the compression /// method and window size, then the DEFLATE stream, then a four-byte big-endian Adler-32 of the /// expanded data. The header must name method 8 with a window of at most 32 KiB and pass its /// own check value, or the call fails with `error.BadHeader`. A header that asks for a preset /// dictionary fails with `error.PresetDictionaryUnsupported`. zlib, /// The gzip container of RFC 1952. The layout is a header of at least ten bytes, then the /// DEFLATE stream, then a little-endian CRC-32 of the expanded data and the expanded length /// modulo 2^32. The optional extra field, file name and comment in the header are skipped, and /// the optional header checksum is checked. One call reads one gzip member, so a second member /// joined after the first counts as leftover input. gzip,};Source: lib/deflate/src/root.zig:50
zig
pub const Format = model.Format;Audit
| Definitions | 1 |
|---|---|
| Public names | 1 |
| Members | 3 |
| Version | 26.7.0 |
| Revision | daab053ee433 |