#[derive(Service)]Expand description
Derive macro for Service structs - generates ServiceFactory implementation
ⓘ
#[derive(Service)]
struct PaymentService {
config: Res<Config>,
orders: Client<OrderService>,
}Generates:
ⓘ
impl ::archy::ServiceFactory for PaymentService {
fn create(app: &::archy::App) -> Self {
PaymentService {
config: app.extract(),
orders: app.extract(),
}
}
}