aboutsummaryrefslogtreecommitdiff
path: root/examples/async/interfaces/food.rs
blob: e85519ba2bd04036677fa7bde04775d9bc437391 (plain)
1
2
3
4
5
6
7
8
9
use syrette::factory;

pub trait IFood: Send + Sync
{
    fn eat(&self);
}

#[factory(threadsafe = true)]
pub type IFoodFactory = dyn Fn() -> dyn IFood;