pub struct CommandHandler<T: Clone + Send + Sync> {
pub module: String,
pub name: String,
pub func: fn(CommandContext<T>) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>>,
}Fields§
§module: String§name: String§func: fn(CommandContext<T>) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>>Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for CommandHandler<T>
impl<T> RefUnwindSafe for CommandHandler<T>
impl<T> Send for CommandHandler<T>
impl<T> Sync for CommandHandler<T>
impl<T> Unpin for CommandHandler<T>
impl<T> UnwindSafe for CommandHandler<T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more