// Services {% for service in services %} pub struct {{ service.name|capitalize }} { db: SqlitePool, } impl {{ service.name|capitalize }} { pub fn new(db: SqlitePool) -> Self { Self { db } } {% for function in service.functions %} pub async fn {{ function.name }}(&self, {% for param in function.parameters %}{{ param.name }}: {{ param.field_type|rust_type }}{% if not loop.last %}, {% endif %}{% endfor %}) -> Result<{{ function.return_type|rust_type }}, WyreError> { // TODO: Implement {{ function.name }} logic {% for attribute in function.attributes %} // Attribute: {{ attribute }} {% endfor %} unimplemented!("{{ function.name }} not implemented") } {% endfor %} } {% endfor %}