Enum redis::acl::Rule[][src]

pub enum Rule {
Show variants On, Off, AddCommand(String), RemoveCommand(String), AddCategory(String), RemoveCategory(String), AllCommands, NoCommands, AddPass(String), RemovePass(String), AddHashedPass(String), RemoveHashedPass(String), NoPass, ResetPass, Pattern(String), AllKeys, ResetKeys, Reset,
}
This is supported on crate feature acl only.
Expand description

ACL rules are used in order to activate or remove a flag, or to perform a given change to the user ACL, which under the hood are just single words.

Variants

On
Expand description

Enable the user: it is possible to authenticate as this user.

Off
Expand description

Disable the user: it’s no longer possible to authenticate with this user, however the already authenticated connections will still work.

AddCommand(String)
Expand description

Add the command to the list of commands the user can call.

RemoveCommand(String)
Expand description

Remove the command to the list of commands the user can call.

AddCategory(String)
Expand description

Add all the commands in such category to be called by the user.

RemoveCategory(String)
Expand description

Remove the commands from such category the client can call.

AllCommands
Expand description

Alias for +@all. Note that it implies the ability to execute all the future commands loaded via the modules system.

NoCommands
Expand description

Alias for -@all.

AddPass(String)
Expand description

Add this password to the list of valid password for the user.

RemovePass(String)
Expand description

Remove this password from the list of valid passwords.

AddHashedPass(String)
Expand description

Add this SHA-256 hash value to the list of valid passwords for the user.

RemoveHashedPass(String)
Expand description

Remove this hash value from from the list of valid passwords

NoPass
Expand description

All the set passwords of the user are removed, and the user is flagged as requiring no password: it means that every password will work against this user.

ResetPass
Expand description

Flush the list of allowed passwords. Moreover removes the nopass status.

Pattern(String)
Expand description

Add a pattern of keys that can be mentioned as part of commands.

AllKeys
Expand description

Alias for ~*.

ResetKeys
Expand description

Flush the list of allowed keys patterns.

Reset
Expand description

Performs the following actions: resetpass, resetkeys, off, -@all. The user returns to the same state it has immediately after its creation.

Trait Implementations

impl Debug for Rule[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl PartialEq<Rule> for Rule[src]

fn eq(&self, other: &Rule) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, other: &Rule) -> bool[src]

This method tests for !=.

impl ToRedisArgs for Rule[src]

fn write_redis_args<W: ?Sized>(&self, out: &mut W) where
    W: RedisWrite
[src]

This writes the value into a vector of bytes. Each item is a single argument. Most items generate a single item. Read more

fn to_redis_args(&self) -> Vec<Vec<u8>>[src]

This converts the value into a vector of bytes. Each item is a single argument. Most items generate a vector of a single item. Read more

fn describe_numeric_behavior(&self) -> NumericBehavior[src]

Returns an information about the contained value with regards to it’s numeric behavior in a redis context. This is used in some high level concepts to switch between different implementations of redis functions (for instance INCR vs INCRBYFLOAT). Read more

fn is_single_arg(&self) -> bool[src]

Returns an indiciation if the value contained is exactly one argument. It returns false if it’s zero or more than one. This is used in some high level functions to intelligently switch between GET and MGET variants. Read more

impl Eq for Rule[src]

impl StructuralEq for Rule[src]

impl StructuralPartialEq for Rule[src]

Auto Trait Implementations

impl RefUnwindSafe for Rule

impl Send for Rule

impl Sync for Rule

impl Unpin for Rule

impl UnwindSafe for Rule

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

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

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

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

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

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

pub fn into(self) -> U[src]

Performs the conversion.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

Performs the conversion.

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

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

The type returned in the event of a conversion error.

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

Performs the conversion.

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

pub fn vzip(self) -> V