pub struct CommandInfo {
    pub name: String,
    pub arity: isize,
    pub flags: Vec<String>,
    pub first_key: usize,
    pub last_key: isize,
    pub step: usize,
    pub acl_categories: Vec<String>,
    pub command_tips: Vec<CommandTip>,
    pub key_specifications: Vec<KeySpecification>,
    pub sub_commands: Vec<CommandInfo>,
}
Expand description

Command info result for the command command.

Fields

name: String

This is the command’s name in lowercase.

arity: isize

Arity is the number of arguments a command expects. It follows a simple pattern:

  • A positive integer means a fixed number of arguments.
  • A negative integer means a minimal number of arguments.
flags: Vec<String>

Command flags are an array. See COMMAND documentation for the list of flags

first_key: usize

The position of the command’s first key name argument. For most commands, the first key’s position is 1. Position 0 is always the command name itself.

last_key: isize

The position of the command’s last key name argument.

step: usize

The step, or increment, between the first key and the position of the next key.

acl_categories: Vec<String>

[From Redis 6.0] This is an array of simple strings that are the ACL categories to which the command belongs.

command_tips: Vec<CommandTip>

[From Redis 7.0] Helpful information about the command. To be used by clients/proxies. See https://redis.io/docs/reference/command-tips/

key_specifications: Vec<KeySpecification>

[From Redis 7.0] This is an array consisting of the command’s key specifications. See https://redis.io/docs/reference/key-specs/

sub_commands: Vec<CommandInfo>

Trait Implementations

Formats the value using the given formatter. Read more
Used to do Value to user type conversion Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

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

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more