pub enum CompressionMethod {
Show 19 variants
Stored,
Deflated,
Deflate64,
Bzip2,
Lzma,
Zstd,
Xz,
Shrunk,
Reduced,
Imploded,
DclImploded,
IbmCmpsc,
IbmTerse,
IbmLz77,
Mp3,
Jpeg,
WavPack,
Ppmd,
Unknown(u16),
}Expand description
ZIP compression method, mirroring zip-rs CompressionMethod for the common
methods plus an Unknown(raw) that preserves the offending value.
Variants§
Stored
Method 0 — no compression (raw passthrough / in-place window).
Deflated
Method 8 — classic DEFLATE.
Deflate64
Method 9 — Deflate64 / “enhanced deflate”.
Bzip2
Method 12 — bzip2.
Lzma
Method 14 — LZMA (with the 4-byte ZIP wrapper prefix).
Zstd
Method 93 — Zstandard.
Xz
Method 95 — XZ.
Shrunk
Method 1 — legacy Shrink (not decoded; recognized so it can be named).
Reduced
Methods 2–5 — legacy Reduce (not decoded).
Imploded
Method 6 — legacy Implode (not decoded).
DclImploded
Method 10 — PKWARE DCL Implode (not decoded).
IbmCmpsc
Method 16 — IBM z/OS CMPSC (not decoded).
IbmTerse
Method 18 — IBM TERSE (not decoded).
IbmLz77
Method 19 — IBM LZ77 / PFS (not decoded).
Mp3
Method 94 — MP3 (not decoded).
Jpeg
Method 96 — JPEG variant (not decoded).
WavPack
Method 97 — WavPack (not decoded).
Ppmd
Method 98 — PPMd (not decoded).
Unknown(u16)
Any other method id — value preserved so callers can report it.
Trait Implementations§
Source§impl Clone for CompressionMethod
impl Clone for CompressionMethod
Source§fn clone(&self) -> CompressionMethod
fn clone(&self) -> CompressionMethod
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for CompressionMethod
Source§impl Debug for CompressionMethod
impl Debug for CompressionMethod
impl Eq for CompressionMethod
Source§impl PartialEq for CompressionMethod
impl PartialEq for CompressionMethod
Source§fn eq(&self, other: &CompressionMethod) -> bool
fn eq(&self, other: &CompressionMethod) -> bool
self and other values to be equal, and is used by ==.