Struct Storage

Source
pub struct Storage { /* private fields */ }

Implementations§

Source§

impl Storage

Source§

impl Storage

Source

pub async fn strings_append(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_get(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_set(&mut self, args: Arguments) -> ExecResult

Source

pub async fn strings_setex_impl( &mut self, key: Key, timepoint: SystemTime, value: Vec<u8>, ) -> ExecResult

Source

pub async fn strings_setex(&mut self, args: Arguments) -> ExecResult

Source

pub async fn strings_psetex(&mut self, args: Arguments) -> ExecResult

Source

pub async fn strings_setnx(&mut self, args: Arguments) -> ExecResult

Source

pub async fn strings_getset(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_len(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_incrby(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_decrby(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_incrby_float(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_bitcount(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_mget(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_mset(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_bitop(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_setbit(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_getbit(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_get_range(&self, args: Arguments) -> ExecResult

Source

pub async fn strings_set_range(&self, args: Arguments) -> ExecResult

Source§

impl Storage

Source

pub async fn expire_key_at(&mut self, key: &Key, timepoint: SystemTime)

Source§

impl Storage

Source

pub async fn list_len(&self, args: Arguments) -> ExecResult

Source

pub async fn list_lpush(&self, args: Arguments) -> ExecResult

Source

pub async fn list_rpush(&self, args: Arguments) -> ExecResult

Source

pub async fn list_lpushx(&self, args: Arguments) -> ExecResult

Source

pub async fn list_rpushx(&self, args: Arguments) -> ExecResult

Source

pub async fn list_lpop(&self, args: Arguments) -> ExecResult

Source

pub async fn list_rpop(&self, args: Arguments) -> ExecResult

Source

pub async fn list_rem(&self, args: Arguments) -> ExecResult

Source

pub async fn list_set(&self, args: Arguments) -> ExecResult

Source

pub async fn list_index(&self, args: Arguments) -> ExecResult

Source

pub async fn list_range(&self, args: Arguments) -> ExecResult

Source

pub async fn list_insert(&self, args: Arguments) -> ExecResult

Source

pub async fn list_trim(&self, args: Arguments) -> ExecResult

Source

pub async fn _list_rpop_lpush(&self, args: Arguments) -> ExecResult

Source§

impl Storage

Source

pub fn make_container(cnt: Container) -> Arc<Mutex<Container>>

Source

pub fn make_container_with<F: FnMut() -> Container>( factory: F, ) -> Arc<Mutex<Container>>

Source

pub async fn try_get_container( &self, key: &Key, ) -> Option<Arc<Mutex<Container>>>

Source

pub async fn get_container<F: FnMut() -> Container>( &self, key: Key, factory: F, ) -> Arc<Mutex<Container>>

Source

pub async fn try_get_containers( &self, keys: &Vec<Key>, ) -> Vec<Option<Arc<Mutex<Container>>>>

Source

pub async fn get_containers<F: FnMut() -> Container>( &self, keys: Vec<Key>, factory: F, ) -> Vec<Arc<Mutex<Container>>>

Source

pub async fn lock_all<'a, T: 'a>( writes: impl Iterator<Item = &'a Mutex<T>>, reads: impl Iterator<Item = Option<&'a Mutex<T>>>, ) -> (Vec<MutexGuard<'a, T>>, Vec<Option<MutexGuard<'a, T>>>)

Source

pub async fn keys_keys(&self, args: Arguments) -> ExecResult

Source

pub async fn keys_exists(&self, args: Arguments) -> ExecResult

Source

pub async fn keys_now(&self, _args: Arguments) -> ExecResult

Source

pub async fn keys_pnow(&self, _args: Arguments) -> ExecResult

Source

pub async fn keys_del(&self, args: Arguments) -> ExecResult

Source

pub async fn keys_rename(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_type(&self, args: Arguments) -> ExecResult

Source

pub async fn keys_pttl(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_ttl(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_expire(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_expire_at(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_pexpire(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_pexpire_at(&mut self, args: Arguments) -> ExecResult

Source

pub async fn keys_check_expirations(&self)

Source

pub async fn keys_scan(&self, args: Arguments) -> ExecResult

Source§

impl Storage

Source

pub async fn hash_set(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_set_nx(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_del(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_get(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_mget(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_get_all(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_exists(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_keys(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_values(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_len(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_strlen(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_incrby(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_incrbyfloat(&self, args: Arguments) -> ExecResult

Source

pub async fn hash_scan(&self, args: Arguments) -> ExecResult

Source§

impl Storage

Source

pub async fn set_card(&self, args: Arguments) -> ExecResult

Source

pub async fn set_members(&self, args: Arguments) -> ExecResult

Source

pub async fn set_is_member(&self, args: Arguments) -> ExecResult

Source

pub async fn set_add(&self, args: Arguments) -> ExecResult

Source

pub async fn set_rem(&self, args: Arguments) -> ExecResult

Source

pub async fn set_pop(&self, args: Arguments) -> ExecResult

Source

pub async fn set_move(&self, args: Arguments) -> ExecResult

Source

pub async fn set_diff(&self, args: Arguments) -> ExecResult

Source

pub async fn set_diff_store(&self, args: Arguments) -> ExecResult

Source

pub async fn set_inter(&self, args: Arguments) -> ExecResult

Source

pub async fn set_inter_store(&self, args: Arguments) -> ExecResult

Source

pub async fn set_union(&self, args: Arguments) -> ExecResult

Source

pub async fn set_union_store(&self, args: Arguments) -> ExecResult

Source

pub async fn _set_rand_member(&self, args: Arguments) -> ExecResult

Source

pub async fn set_scan(&self, args: Arguments) -> ExecResult

Source§

impl Storage

Source

pub fn new() -> Self

Source

pub fn set_expire_awaker<A>(&mut self, a: A)
where A: FnMut(SystemTime) + Send + 'static,

Source

pub async fn unimplemented(&self) -> ExecResult

Source

pub async fn execute(&mut self, command: Command) -> Value

Trait Implementations§

Source§

impl Clone for Storage

Source§

fn clone(&self) -> Storage

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V