lz-str 0.1.0

A port of lz-string to Rust
Documentation

lz-str-rs

Rust

A port of lz-string to Rust.

Installing

Add the following to your Cargo.toml file:

[dependencies]

lz-str = { git = "https://github.com/adumbidiot/lz-str-rs" }

Getting Started

use lz_str::{
    compress_str,
    decompress_str,
};

const DATA_STR: &'static str = "The quick brown fox jumps over the lazy dog";

fn main(){
    let compressed = compress_str(&DATA_STR);
    let decompressed = decompress_str(&compressed).unwrap();
    assert_eq!(DATA_STR, decompressed);
}

Testing

cargo test

Benching

cargo bench

Authors

adumbidiot (Nathaniel Daniel)

License

Licensed under either of

at your option.

Contributing

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.