Struct redis_client::redis::RedisClient
[−]
[src]
pub struct RedisClient { // some fields omitted }
Methods
impl RedisClient
A RedisClient is a structure to send command to redis and receive the response. All RedisClient's methods are performed synchronously.
When creating a RedisClient it will automatically create a connection. Therefore when it is created it uses the host and the port.
Example:
let mut client = try!(redis_client::RedisClient::new("127.0.0.1", "6379"));
fn new(host: &'static str, port: &'static str) -> Result<RedisClient, RedisError>
fn exec_redis_command(&mut self, redis_command: &mut RedisCommand) -> Result<RedisResult, RedisError>
Execute a RedisCommand
fn exec_redis_pipeline_command(&mut self, redis_command: &mut RedisCommand) -> Result<Vec<RedisResult>, RedisError>
Execute a pipeline of RedisCommand