Trait serenity::framework::standard::Command[][src]

pub trait Command: Send + Sync + 'static {
    fn execute(
        &self,
        _: &mut Context,
        _: &Message,
        _: Args
    ) -> Result<(), Error>; fn options(&self) -> Arc<CommandOptions> { ... }
fn init(&self) { ... }
fn before(&self, &mut Context, &Message) -> bool { ... }
fn after(&self, &mut Context, &Message, &Result<(), Error>) { ... } }

A framework command.

Required Methods

Provided Methods

Called when the command gets registered.

"before" middleware. Is called alongside the global middleware in the framework.

"after" middleware. Is called alongside the global middleware in the framework.

Implementations on Foreign Types

impl Command for Arc<Command>
[src]

Implementors