pub struct PooledConnection { /* private fields */ }Expand description
A pooled connection that returns to the pool on drop.
Methods from Deref<Target = RedisDriver>§
Sourcepub async fn execute(&mut self, cmd: &Qail) -> RedisResult<Value>
pub async fn execute(&mut self, cmd: &Qail) -> RedisResult<Value>
Execute a Qail command.
Sourcepub async fn set_ex(
&mut self,
key: &str,
value: &[u8],
seconds: i64,
) -> RedisResult<()>
pub async fn set_ex( &mut self, key: &str, value: &[u8], seconds: i64, ) -> RedisResult<()>
SET key value EX seconds
Sourcepub async fn del(&mut self, key: &str) -> RedisResult<i64>
pub async fn del(&mut self, key: &str) -> RedisResult<i64>
DEL key
Sourcepub async fn incr(&mut self, key: &str) -> RedisResult<i64>
pub async fn incr(&mut self, key: &str) -> RedisResult<i64>
INCR key
Sourcepub async fn ttl(&mut self, key: &str) -> RedisResult<i64>
pub async fn ttl(&mut self, key: &str) -> RedisResult<i64>
TTL key
Sourcepub async fn expire(&mut self, key: &str, seconds: i64) -> RedisResult<bool>
pub async fn expire(&mut self, key: &str, seconds: i64) -> RedisResult<bool>
EXPIRE key seconds
Sourcepub async fn exists(&mut self, key: &str) -> RedisResult<bool>
pub async fn exists(&mut self, key: &str) -> RedisResult<bool>
EXISTS key
Sourcepub async fn ping(&mut self) -> RedisResult<bool>
pub async fn ping(&mut self) -> RedisResult<bool>
PING
Trait Implementations§
Source§impl Deref for PooledConnection
impl Deref for PooledConnection
Source§impl DerefMut for PooledConnection
impl DerefMut for PooledConnection
Auto Trait Implementations§
impl !Freeze for PooledConnection
impl !RefUnwindSafe for PooledConnection
impl Send for PooledConnection
impl Sync for PooledConnection
impl Unpin for PooledConnection
impl !UnwindSafe for PooledConnection
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