[][src]Struct redis::Client

pub struct Client { /* fields omitted */ }

The client type.

Methods

impl Client[src]

The client acts as connector to the redis server. By itself it does not do much other than providing a convenient way to fetch a connection from it. In the future the plan is to provide a connection pool in the client.

When opening a client a URL in the following format should be used:

redis://host:port/db

Example usage::

let client = redis::Client::open("redis://127.0.0.1/").unwrap();
let con = client.get_connection().unwrap();

pub fn open<T: IntoConnectionInfo>(params: T) -> RedisResult<Client>[src]

Connects to a redis server and returns a client. This does not actually open a connection yet but it does perform some basic checks on the URL that might make the operation fail.

pub fn get_connection(&self) -> RedisResult<Connection>[src]

Instructs the client to actually connect to redis and returns a connection object. The connection object can be used to send commands to the server. This can fail with a variety of errors (like unreachable host) so it's important that you handle those errors.

pub fn get_async_connection(
    &self
) -> impl Future<Item = Connection, Error = RedisError>
[src]

pub fn get_shared_async_connection(
    &self
) -> impl Future<Item = SharedConnection, Error = RedisError>
[src]

Trait Implementations

impl ConnectionLike for Client[src]

impl Commands for Client[src]

fn get<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Get the value of a key. If key is a vec this becomes an MGET.

fn keys<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Gets all keys matching pattern

fn set<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Set the string value of a key.

fn set_multiple<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    items: &[(K, V)]
) -> RedisResult<RV>
[src]

Sets multiple keys to their values.

fn set_ex<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V,
    seconds: usize
) -> RedisResult<RV>
[src]

Set the value and expiration of a key.

fn set_nx<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Set the value of a key, only if the key does not exist

fn mset_nx<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    items: &[(K, V)]
) -> RedisResult<RV>
[src]

Sets multiple keys to their values failing if at least one already exists.

fn getset<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Set the string value of a key and return its old value.

fn del<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Delete one or more keys.

fn exists<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Determine if a key exists.

fn expire<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    seconds: usize
) -> RedisResult<RV>
[src]

Set a key's time to live in seconds.

fn expire_at<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    ts: usize
) -> RedisResult<RV>
[src]

Set the expiration for a key as a UNIX timestamp.

fn pexpire<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    ms: usize
) -> RedisResult<RV>
[src]

Set a key's time to live in milliseconds.

fn pexpire_at<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    ts: usize
) -> RedisResult<RV>
[src]

Set the expiration for a key as a UNIX timestamp in milliseconds.

fn persist<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Remove the expiration from a key.

fn ttl<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Check the expiration time of a key.

fn rename<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    new_key: K
) -> RedisResult<RV>
[src]

Rename a key.

fn rename_nx<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    new_key: K
) -> RedisResult<RV>
[src]

Rename a key, only if the new key does not exist.

fn append<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Append a value to a key.

fn incr<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    delta: V
) -> RedisResult<RV>
[src]

Increment the numeric value of a key by the given amount. This issues a INCRBY or INCRBYFLOAT depending on the type. Read more

fn setbit<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    offset: usize,
    value: bool
) -> RedisResult<RV>
[src]

Sets or clears the bit at offset in the string value stored at key.

fn getbit<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    offset: usize
) -> RedisResult<RV>
[src]

Returns the bit value at offset in the string value stored at key.

fn bitcount<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K
) -> RedisResult<RV>
[src]

Count set bits in a string.

fn bitcount_range<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: usize,
    end: usize
) -> RedisResult<RV>
[src]

Count set bits in a string in a range.

fn bit_and<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    srckeys: K
) -> RedisResult<RV>
[src]

Perform a bitwise AND between multiple keys (containing string values) and store the result in the destination key. Read more

fn bit_or<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    srckeys: K
) -> RedisResult<RV>
[src]

Perform a bitwise OR between multiple keys (containing string values) and store the result in the destination key. Read more

fn bit_xor<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    srckeys: K
) -> RedisResult<RV>
[src]

Perform a bitwise XOR between multiple keys (containing string values) and store the result in the destination key. Read more

fn bit_not<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    srckey: K
) -> RedisResult<RV>
[src]

Perform a bitwise NOT of the key (containing string values) and store the result in the destination key. Read more

fn strlen<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Get the length of the value stored in a key.

fn hget<K: ToRedisArgs, F: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    field: F
) -> RedisResult<RV>
[src]

Gets a single (or multiple) fields from a hash.

fn hdel<K: ToRedisArgs, F: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    field: F
) -> RedisResult<RV>
[src]

Deletes a single (or multiple) fields from a hash.

fn hset<K: ToRedisArgs, F: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    field: F,
    value: V
) -> RedisResult<RV>
[src]

Sets a single field in a hash.

fn hset_nx<K: ToRedisArgs, F: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    field: F,
    value: V
) -> RedisResult<RV>
[src]

Sets a single field in a hash if it does not exist.

fn hset_multiple<K: ToRedisArgs, F: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    items: &[(F, V)]
) -> RedisResult<RV>
[src]

Sets a multiple fields in a hash.

fn hincr<K: ToRedisArgs, F: ToRedisArgs, D: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    field: F,
    delta: D
) -> RedisResult<RV>
[src]

Increments a value.

fn hexists<K: ToRedisArgs, F: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    field: F
) -> RedisResult<RV>
[src]

Checks if a field in a hash exists.

fn hkeys<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Gets all the keys in a hash.

fn hvals<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Gets all the values in a hash.

fn hgetall<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Gets all the fields and values in a hash.

fn hlen<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Gets the length of a hash.

fn blpop<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    timeout: usize
) -> RedisResult<RV>
[src]

Remove and get the first element in a list, or block until one is available.

fn brpop<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    timeout: usize
) -> RedisResult<RV>
[src]

Remove and get the last element in a list, or block until one is available.

fn brpoplpush<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    srckey: K,
    dstkey: K,
    timeout: usize
) -> RedisResult<RV>
[src]

Pop a value from a list, push it to another list and return it; or block until one is available. Read more

fn lindex<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    index: isize
) -> RedisResult<RV>
[src]

Get an element from a list by its index.

fn linsert_before<K: ToRedisArgs, P: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    pivot: P,
    value: V
) -> RedisResult<RV>
[src]

Insert an element before another element in a list.

fn linsert_after<K: ToRedisArgs, P: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    pivot: P,
    value: V
) -> RedisResult<RV>
[src]

Insert an element after another element in a list.

fn llen<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Returns the length of the list stored at key.

fn lpop<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Removes and returns the first element of the list stored at key.

fn lpush<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Insert all the specified values at the head of the list stored at key.

fn lpush_exists<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Inserts a value at the head of the list stored at key, only if key already exists and holds a list. Read more

fn lrange<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Returns the specified elements of the list stored at key.

fn lrem<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    count: isize,
    value: V
) -> RedisResult<RV>
[src]

Removes the first count occurrences of elements equal to value from the list stored at key. Read more

fn ltrim<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Trim an existing list so that it will contain only the specified range of elements specified. Read more

fn lset<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    index: isize,
    value: V
) -> RedisResult<RV>
[src]

Sets the list element at index to value

fn rpop<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Removes and returns the last element of the list stored at key.

fn rpoplpush<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    dstkey: K
) -> RedisResult<RV>
[src]

Pop a value from a list, push it to another list and return it.

fn rpush<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Insert all the specified values at the tail of the list stored at key.

fn rpush_exists<K: ToRedisArgs, V: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    value: V
) -> RedisResult<RV>
[src]

Inserts value at the tail of the list stored at key, only if key already exists and holds a list. Read more

fn sadd<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M
) -> RedisResult<RV>
[src]

Add one or more members to a set.

fn scard<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Get the number of members in a set.

fn sdiff<K: ToRedisArgs, RV: FromRedisValue>(&self, keys: K) -> RedisResult<RV>[src]

Subtract multiple sets.

fn sdiffstore<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: K
) -> RedisResult<RV>
[src]

Subtract multiple sets and store the resulting set in a key.

fn sinter<K: ToRedisArgs, RV: FromRedisValue>(&self, keys: K) -> RedisResult<RV>[src]

Intersect multiple sets.

fn sdinterstore<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: K
) -> RedisResult<RV>
[src]

Intersect multiple sets and store the resulting set in a key.

fn sismember<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M
) -> RedisResult<RV>
[src]

Determine if a given value is a member of a set.

fn smembers<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K
) -> RedisResult<RV>
[src]

Get all the members in a set.

fn smove<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    srckey: K,
    dstkey: K,
    member: M
) -> RedisResult<RV>
[src]

Move a member from one set to another.

fn spop<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Remove and return a random member from a set.

fn srandmember<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K
) -> RedisResult<RV>
[src]

Get one random member from a set.

fn srandmember_multiple<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    count: usize
) -> RedisResult<RV>
[src]

Get multiple random members from a set.

fn srem<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M
) -> RedisResult<RV>
[src]

Remove one or more members from a set.

fn sunion<K: ToRedisArgs, RV: FromRedisValue>(&self, keys: K) -> RedisResult<RV>[src]

Add multiple sets.

fn sunionstore<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: K
) -> RedisResult<RV>
[src]

Add multiple sets and store the resulting set in a key.

fn zadd<K: ToRedisArgs, S: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M,
    score: S
) -> RedisResult<RV>
[src]

Add one member to a sorted set, or update its score if it already exists.

fn zadd_multiple<K: ToRedisArgs, S: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    items: &[(S, M)]
) -> RedisResult<RV>
[src]

Add multiple members to a sorted set, or update its score if it already exists.

fn zcard<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Get the number of members in a sorted set.

fn zcount<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM
) -> RedisResult<RV>
[src]

Count the members in a sorted set with scores within the given values.

fn zincr<K: ToRedisArgs, M: ToRedisArgs, D: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M,
    delta: D
) -> RedisResult<RV>
[src]

Increments the member in a sorted set at key by delta. If the member does not exist, it is added with delta as its score. Read more

fn zinterstore<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: &[K]
) -> RedisResult<RV>
[src]

Intersect multiple sorted sets and store the resulting sorted set in a new key using SUM as aggregation function. Read more

fn zinterstore_min<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: &[K]
) -> RedisResult<RV>
[src]

Intersect multiple sorted sets and store the resulting sorted set in a new key using MIN as aggregation function. Read more

fn zinterstore_max<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: &[K]
) -> RedisResult<RV>
[src]

Intersect multiple sorted sets and store the resulting sorted set in a new key using MAX as aggregation function. Read more

fn zlexcount<K: ToRedisArgs, L: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: L,
    max: L
) -> RedisResult<RV>
[src]

Count the number of members in a sorted set between a given lexicographical range.

fn zrange<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by index

fn zrange_withscores<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by index with scores.

fn zrangebylex<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by lexicographical range.

fn zrangebylex_limit<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM,
    offset: isize,
    count: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by lexicographical range with offset and limit. Read more

fn zrevrangebylex<K: ToRedisArgs, MM: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    max: MM,
    min: M
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by lexicographical range.

fn zrevrangebylex_limit<K: ToRedisArgs, MM: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    max: MM,
    min: M,
    offset: isize,
    count: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by lexicographical range with offset and limit. Read more

fn zrangebyscore<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score.

fn zrangebyscore_withscores<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score with scores.

fn zrangebyscore_limit<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM,
    offset: isize,
    count: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score with limit.

fn zrangebyscore_limit_withscores<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM,
    offset: isize,
    count: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score with limit with scores.

fn zrank<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M
) -> RedisResult<RV>
[src]

Determine the index of a member in a sorted set.

fn zrem<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    members: M
) -> RedisResult<RV>
[src]

Remove one or more members from a sorted set.

fn zrembylex<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM
) -> RedisResult<RV>
[src]

Remove all members in a sorted set between the given lexicographical range.

fn zrembyrank<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Remove all members in a sorted set within the given indexes.

fn zrembyscore<K: ToRedisArgs, M: ToRedisArgs, MM: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    min: M,
    max: MM
) -> RedisResult<RV>
[src]

Remove all members in a sorted set within the given scores.

fn zrevrange<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by index, with scores ordered from high to low. Read more

fn zrevrange_withscores<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    start: isize,
    stop: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by index, with scores ordered from high to low. Read more

fn zrevrangebyscore<K: ToRedisArgs, MM: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    max: MM,
    min: M
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score.

fn zrevrangebyscore_withscores<K: ToRedisArgs, MM: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    max: MM,
    min: M
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score with scores.

fn zrevrangebyscore_limit<K: ToRedisArgs, MM: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    max: MM,
    min: M,
    offset: isize,
    count: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score with limit.

fn zrevrangebyscore_limit_withscores<K: ToRedisArgs, MM: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    max: MM,
    min: M,
    offset: isize,
    count: isize
) -> RedisResult<RV>
[src]

Return a range of members in a sorted set, by score with limit with scores.

fn zrevrank<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M
) -> RedisResult<RV>
[src]

Determine the index of a member in a sorted set, with scores ordered from high to low.

fn zscore<K: ToRedisArgs, M: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    member: M
) -> RedisResult<RV>
[src]

Get the score associated with the given member in a sorted set.

fn zunionstore<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: &[K]
) -> RedisResult<RV>
[src]

Unions multiple sorted sets and store the resulting sorted set in a new key using SUM as aggregation function. Read more

fn zunionstore_min<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: &[K]
) -> RedisResult<RV>
[src]

Unions multiple sorted sets and store the resulting sorted set in a new key using MIN as aggregation function. Read more

fn zunionstore_max<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    keys: &[K]
) -> RedisResult<RV>
[src]

Unions multiple sorted sets and store the resulting sorted set in a new key using MAX as aggregation function. Read more

fn pfadd<K: ToRedisArgs, E: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    element: E
) -> RedisResult<RV>
[src]

Adds the specified elements to the specified HyperLogLog.

fn pfcount<K: ToRedisArgs, RV: FromRedisValue>(&self, key: K) -> RedisResult<RV>[src]

Return the approximated cardinality of the set(s) observed by the HyperLogLog at key(s). Read more

fn pfmerge<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    dstkey: K,
    srckeys: K
) -> RedisResult<RV>
[src]

Merge N different HyperLogLogs into a single one.

fn publish<K: ToRedisArgs, E: ToRedisArgs, RV: FromRedisValue>(
    &self,
    channel: K,
    message: E
) -> RedisResult<RV>
[src]

Posts a message to the given channel.

fn scan<RV: FromRedisValue>(&self) -> RedisResult<Iter<RV>>[src]

Incrementally iterate the keys space.

fn scan_match<P: ToRedisArgs, RV: FromRedisValue>(
    &self,
    pattern: P
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate the keys space for keys matching a pattern.

fn hscan<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate hash fields and associated values.

fn hscan_match<K: ToRedisArgs, P: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    pattern: P
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate hash fields and associated values for field names matching a pattern. Read more

fn sscan<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate set elements.

fn sscan_match<K: ToRedisArgs, P: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    pattern: P
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate set elements for elements matching a pattern.

fn zscan<K: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate sorted set elements.

fn zscan_match<K: ToRedisArgs, P: ToRedisArgs, RV: FromRedisValue>(
    &self,
    key: K,
    pattern: P
) -> RedisResult<Iter<RV>>
[src]

Incrementally iterate sorted set elements for elements matching a pattern.

impl Clone for Client[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for Client[src]

Auto Trait Implementations

impl Send for Client

impl Sync for Client

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Erased for T