Compression FiltersWhile the Compression Wrappers provide a way of creating gzip and bz2 compatible files on the local filesystem, they do not provide a means for generalized compression over network streams, nor do they provide a means to begin with a non-compressed stream and transition to a compressed one. For this, a compression filter may be applied to any stream resource at any time.
zlib.deflate and zlib.inflate
zlib.* compression filters are available if zlib support is enabled. Example #1
Example #2
bzip2.compress and bzip2.decompress
bzip2.* compression filters are available if bz2 support is enabled. Example #3
|