compio_driver

Trait Dispatchable

source
pub trait Dispatchable: Send + 'static {
    // Required method
    fn run(self: Box<Self>);
}
Expand description

A trait for dispatching a closure. It’s implemented for all `FnOnce() + Send

  • ’staticbut may also be implemented for any other types that areSendand’static`.

Required Methods§

source

fn run(self: Box<Self>)

Run the dispatchable

Implementors§

source§

impl<F> Dispatchable for F
where F: FnOnce() + Send + 'static,