#blast #dcl #io-read #pkware #implode

explode

A decompression implementation for the implode algorithm from the PKWARE Data Compression Library

3 releases

0.1.2 Aug 21, 2020
0.1.1 Aug 21, 2020
0.1.0 Aug 20, 2020

#497 in Compression

Download history 47/week @ 2024-07-20 55/week @ 2024-07-27 47/week @ 2024-08-03 46/week @ 2024-08-10 43/week @ 2024-08-17 48/week @ 2024-08-24 61/week @ 2024-08-31 33/week @ 2024-09-07 44/week @ 2024-09-14 77/week @ 2024-09-21 52/week @ 2024-09-28 40/week @ 2024-10-05 39/week @ 2024-10-12 36/week @ 2024-10-19 39/week @ 2024-10-26 44/week @ 2024-11-02

163 downloads per month
Used in 3 crates

MIT license

41KB
782 lines

explode

build status crates.io docs.rs

A decompression implementation for the implode algorithm from the PKWARE Data Compression Library.

This implementation is based on blast.c by Mark Adler, distributed with zlib.

Examples

To decompress a block of bytes in memory, use explode.

let bytes = vec![0x00, 0x04, 0x82, 0x24, 0x25, 0x8f, 0x80, 0x7f];
let result = explode::explode(&bytes)?;
assert_eq!(result, "AIAIAIAIAIAIA".as_bytes());

To decompress a File or other type that implements Read, use ExplodeReader.

use std::io::Read;
let mut reader = explode::ExplodeReader::new(some_file);
let mut decompressed = vec![];
reader.read_to_end(&mut decompressed)?;
// or other functions from Read

For more complicated uses that do not fit into these categories, use Explode.

License

Licensed under the MIT license. Unless stated otherwise, any contributions to this work will also be licensed this way, with no additional terms or conditions.

Dependencies

~100KB