Crate minilzo_rs[][src]

Expand description

A pure rust implementation bound to the C version of minilzo.

Example

// compress
let mut lzo = minilzo_rs::LZO::init().unwrap();
let input = [0x00u8; 1024];
let out = lzo.compress(&input).unwrap();

// decompress
let input_o = input.to_owned();
let input = lzo.decompress_safe(&out[..], 1024);
let input = input.unwrap();
assert_eq!(&input_o[..], &input[..]);

Structs

LZO

An example of LZO compression.

Enums

Error

Functions

adler32

Calculate the adler32 value of the data.