zlib-0.3: Compression and decompression in the gzip and zlib formatsContentsIndex
Codec.Compression.Zlib
Portabilityportable (H98 + FFI)
Stabilityexperimental
Maintainerduncan.coutts@worc.ox.ac.uk
Contents
Compression
Decompression
Description

Compression and decompression of data streams in the zlib format.

The format is described in detail in RFC #1950: http://www.ietf.org/rfc/rfc1950.txt

See also the zlib home page: http://zlib.net/

Synopsis
compress :: ByteString -> ByteString
compressWith :: CompressionLevel -> ByteString -> ByteString
data CompressionLevel
= DefaultCompression
| NoCompression
| BestSpeed
| BestCompression
| CompressionLevel Int
decompress :: ByteString -> ByteString
Compression
compress :: ByteString -> ByteString
compressWith :: CompressionLevel -> ByteString -> ByteString
data CompressionLevel
Control amount of compression. This is a trade-off between the amount of compression and the time and memory required to do the compression.
Constructors
DefaultCompressionThe default compression level is 6 (that is, biased towards high compression at expense of speed).
NoCompressionNo compression, just a block copy.
BestSpeedThe fastest compression method (less compression)
BestCompressionThe slowest compression method (best compression).
CompressionLevel IntA specific compression level between 1 and 9.
show/hide Instances
Decompression
decompress :: ByteString -> ByteString
Produced by Haddock version 0.8