[−][src]Trait serenity::framework::Framework
A trait for defining your own framework for serenity to use.
Should you implement this trait, or define a message
handler, depends on you.
However, using this will benefit you by abstracting the EventHandler
away,
and providing a reference to serenity's threadpool,
so that you may run your commands in separate threads.
Required methods
#[must_use]fn dispatch<'life0, 'async_trait>(
&'life0 self,
__arg1: Context,
__arg2: Message
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
&'life0 self,
__arg1: Context,
__arg2: Message
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Implementations on Foreign Types
impl<F: ?Sized> Framework for Box<F> where
F: Framework,
[src]
F: Framework,
fn dispatch<'life0, 'async_trait>(
&'life0 self,
ctx: Context,
msg: Message
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
ctx: Context,
msg: Message
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
impl<'a, F: ?Sized> Framework for &'a mut F where
F: Framework,
[src]
F: Framework,
fn dispatch<'life0, 'async_trait>(
&'life0 self,
ctx: Context,
msg: Message
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
ctx: Context,
msg: Message
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,