rlite

Crates.iorlite
lib.rsrlite
version0.0.1
sourcesrc
created_at2015-08-31 22:39:45.423292
updated_at2015-12-11 23:55:29.371301
descriptionBindings to rlite database
homepage
repositoryhttps://github.com/seppo0010/rlite-rs
max_upload_size
id2973
size8,014
Sebastian Waisbrot (seppo0010)

documentation

http://seppo0010.github.io/rlite-rs/

README

Interface to rlite

rlite is a self-contained, serverless, zero-configuration, transactional redis-compatible database engine. rlite is to Redis what SQLite is to SQL.

Getting Started

rlite-rs is available on crates.io. Add the following dependency to your Cargo manifest:

[dependencies]
rlite = "0.1.0"

Example

let path = Path::new("db.rld");
let rlite = Rlite::file(&path).unwrap();

rlite.write_command(&["set".as_bytes(), "key".as_bytes(), "value".as_bytes()]).unwrap();
assert_eq!(conn.read_reply().unwrap(), Reply::Status("OK".to_owned()));

conn.write_command(&["get".as_bytes(), "key".as_bytes()]).unwrap();
assert_eq!(conn.read_reply().unwrap(), Reply::Data(b"value".to_vec()));
Commit count: 4

cargo fmt