[][src]Struct serenity::framework::standard::CommandOptions

pub struct CommandOptions {
    pub checks: &'static [&'static Check],
    pub bucket: Option<&'static str>,
    pub names: &'static [&'static str],
    pub desc: Option<&'static str>,
    pub delimiters: &'static [&'static str],
    pub usage: Option<&'static str>,
    pub examples: &'static [&'static str],
    pub min_args: Option<u16>,
    pub max_args: Option<u16>,
    pub allowed_roles: &'static [&'static str],
    pub required_permissions: Permissions,
    pub help_available: bool,
    pub only_in: OnlyIn,
    pub owners_only: bool,
    pub owner_privilege: bool,
    pub sub_commands: &'static [&'static Command],
}

Fields

checks: &'static [&'static Check]

A set of checks to be called prior to executing the command. The checks will short-circuit on the first check that returns false.

bucket: Option<&'static str>

Ratelimit bucket.

names: &'static [&'static str]

Names that the command can be referred to.

desc: Option<&'static str>

Command description, used by other commands.

delimiters: &'static [&'static str]

Delimiters used to split the arguments of the command by. If empty, the global delimiters are used.

usage: Option<&'static str>

Command usage schema, used by other commands.

examples: &'static [&'static str]

Example arguments, used by other commands.

min_args: Option<u16>

Minimum amount of arguments that should be passed.

max_args: Option<u16>

Maximum amount of arguments that can be passed.

allowed_roles: &'static [&'static str]

Roles allowed to use this command.

required_permissions: Permissions

Permissions required to use this command.

help_available: bool

Whether the command should be displayed in help list or not, used by other commands.

only_in: OnlyIn

Whether the command can only be used in dms or guilds; or both.

owners_only: bool

Whether the command can only be used by owners or not.

owner_privilege: bool

Whether the command treats owners as normal users.

sub_commands: &'static [&'static Command]

Other commands belonging to this command.

Trait Implementations

impl<'_> CommonOptions for &'_ CommandOptions[src]

impl Debug for CommandOptions[src]

impl Default for CommandOptions[src]

impl PartialEq<CommandOptions> for CommandOptions[src]

impl StructuralPartialEq for CommandOptions[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

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

impl<T> Same<T> for T

type Output = T

Should always be Self

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.

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.

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

impl<T> WithSubscriber for T[src]