Crates.io | logd |
lib.rs | logd |
version | 0.0.1 |
source | src |
created_at | 2016-07-08 01:07:16.749278 |
updated_at | 2016-07-08 01:07:16.749278 |
description | Logging data collector. |
homepage | https://github.com/iorust/logd |
repository | https://github.com/iorust/logd.git |
max_upload_size | |
id | 5606 |
size | 15,486 |
RESP(REdis Serialization Protocol) Serialization for Rust.
Implementations:
extern crate resp;
use resp::{Value, encode, encode_slice, Decoder};
enum Value {
/// Null bulk reply, $-1\r\n
Null,
/// Null array reply, *-1\r\n
NullArray,
/// For Simple Strings the first byte of the reply is "+"
String(String),
/// For Errors the first byte of the reply is "-"
Error(String),
/// For Integers the first byte of the reply is ":"
Integer(i64),
/// For Bulk Strings the first byte of the reply is "$"
Bulk(String),
/// For Bulk <binary> Strings the first byte of the reply is "$"
BufBulk(Vec<u8>),
/// For Arrays the first byte of the reply is "*"
Array(Vec<Value>),
}
value.is_null() -> bool
value.is_error() -> bool
value.encode() -> Vec<u8>
value.to_encoded_string() -> io::Result<String>
value.to_beautify_string() -> String
fn encode(value: &Value) -> Vec<u8>
fn encode_slice(array: &[&str]) -> Vec<u8>
Decoder.new() -> Self
Decoder.with_buf_bulk() -> Self
decoder.feed(buf: &[u8]) -> Result<(), io:Error>
decoder.read() -> Option<Value>
decoder.buffer_len() -> usize
decoder.result_len() -> usize