pub struct RedisClient {
pub client: ConnectionManager,
}
Fields§
§client: ConnectionManager
Implementations§
Source§impl RedisClient
impl RedisClient
pub async fn get<K: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, ) -> RedisResult<String>
pub async fn mget<K: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, ) -> RedisResult<Vec<String>>
pub async fn exists<K: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, ) -> RedisResult<u8>
pub async fn set<K: ToRedisArgs + Debug + Send + Sync, V: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, value: V, ) -> RedisResult<bool>
pub async fn expire<K: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, expire: usize, ) -> RedisResult<i8>
pub async fn del<K: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, ) -> RedisResult<u8>
pub async fn xadd<K: ToRedisArgs + Debug + Send + Sync, F: ToRedisArgs + Debug + Send + Sync, V: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, items: &[(F, V)], ) -> RedisResult<String>
Sourcepub async fn xgroup_create<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync>(
&mut self,
key: K,
group: G,
) -> RedisResult<()>
pub async fn xgroup_create<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, ) -> RedisResult<()>
return OK
Sourcepub async fn xread_group(
&mut self,
key: &str,
group: &str,
consumer: &str,
) -> RedisResult<Value>
pub async fn xread_group( &mut self, key: &str, group: &str, consumer: &str, ) -> RedisResult<Value>
return OK
pub async fn xinfo_groups<K: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, ) -> RedisResult<Value>
pub async fn is_exist_group_name<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, ) -> RedisResult<bool>
pub async fn xinfo_consumers<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, ) -> RedisResult<Value>
pub async fn xclaim_auto<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync, C: ToRedisArgs + Debug + Send + Sync, MIT: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, consumer: C, min_idle_time: MIT, ) -> RedisResult<Value>
pub async fn xpending_one<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, ) -> RedisResult<Value>
pub async fn get_id(&self, data: &Value) -> RedisResult<String>
pub async fn xack<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync, I: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, ids: &Vec<I>, ) -> RedisResult<u64>
pub async fn xack2del<K: ToRedisArgs + Debug + Send + Sync, G: ToRedisArgs + Debug + Send + Sync, I: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, group: G, ids: &Vec<I>, ) -> RedisResult<(u64, u64)>
Sourcepub async fn xdel<K: ToRedisArgs + Debug + Send + Sync, I: ToRedisArgs + Debug + Send + Sync>(
&mut self,
key: K,
ids: &Vec<I>,
) -> RedisResult<u64>
pub async fn xdel<K: ToRedisArgs + Debug + Send + Sync, I: ToRedisArgs + Debug + Send + Sync>( &mut self, key: K, ids: &Vec<I>, ) -> RedisResult<u64>
Trait Implementations§
Source§impl Clone for RedisClient
impl Clone for RedisClient
Source§fn clone(&self) -> RedisClient
fn clone(&self) -> RedisClient
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for RedisClient
impl !RefUnwindSafe for RedisClient
impl Send for RedisClient
impl Sync for RedisClient
impl Unpin for RedisClient
impl !UnwindSafe for RedisClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more