[][src]Enum serenity::framework::standard::DispatchError

pub enum DispatchError {
    CheckFailed,
    CommandDisabled(String),
    BlockedUser,
    BlockedGuild,
    BlockedChannel,
    LackOfPermissions(Permissions),
    RateLimited(i64),
    OnlyForDM,
    OnlyForGuilds,
    OnlyForOwners,
    LackingRole,
    NotEnoughArguments {
        min: i32,
        given: usize,
    },
    TooManyArguments {
        max: i32,
        given: usize,
    },
    IgnoredBot,
    WebhookAuthor,
}

An enum representing all possible fail conditions under which a command won't be executed.

Variants

When a custom function check has failed.

When the requested command is disabled in bot configuration.

When the user is blocked in bot configuration.

When the guild or its owner is blocked in bot configuration.

When the channel blocked in bot configuration.

When the command requester lacks specific required permissions.

When the command requester has exceeded a ratelimit bucket. The attached value is the time a requester has to wait to run the command again.

When the requested command can only be used in a direct message or group channel.

When the requested command can only be ran in guilds, or the bot doesn't support DMs.

When the requested command can only be used by bot owners.

When the requested command requires one role.

When there are too few arguments.

Fields of NotEnoughArguments

When there are too many arguments.

Fields of TooManyArguments

When the command was requested by a bot user when they are set to be ignored.

When the bot ignores webhooks and a command was issued by one.

Trait Implementations

impl Debug for DispatchError
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

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

Performs the conversion.

impl<T> From for T
[src]

Performs the conversion.

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

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

Immutably borrows from an owned value. Read more

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

Mutably borrows from an owned value. Read more

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

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

🔬 This is a nightly-only experimental API. (get_type_id)

this method will likely be replaced by an associated static

Gets the TypeId of self. Read more

impl<T> Erased for T

impl<T> Typeable for T where
    T: Any

Get the TypeId of this object.

impl<T> DebugAny for T where
    T: Any + Debug
[src]

impl<T> UnsafeAny for T where
    T: Any