rust-maglev travis build crate docs

Google's consistent hashing algorithm

Usage

To use maglev, first add this to your Cargo.toml:

toml [dependencies] maglev = "0.1"

Then, add this to your crate root:

```rust extern crate maglev;

use maglev::*; ```

And then, use Maglev with ConsistentHasher trait

```rust let m = Maglev::new(&["Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"][..]);

asserteq!(*m.get(&"alice"), "Friday"); asserteq!(*m.get(&"bob"), "Wednesday"); ```

When the node list changed, ensure to use same capacity to rebuild

```rust let m = Maglev::with_capacity(&["Monday", // "Tuesday", "Wednesday", // "Thursday", "Friday", "Saturday", "Sunday"][..], m.capacity());

asserteq!(*m.get(&"alice"), "Friday"); asserteq!(*m.get(&"bob"), "Wednesday"); ```

Maglev use std::collections::hash_map::DefaultHasher by default, we could use the given hash builder to hash keys.

```rust use fasthash::spooky::SpookyHash128;

let m = Maglev::with_hasher(&["Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"][..], SpookyHash128 {});

asserteq!(*m.get(&"alice"), "Monday"); asserteq!(*m.get(&"bob"), "Wednesday"); ```