puerto 0.10.1

Puerto — Rust full-stack DDD framework CLI. Scaffolds Clean Architecture projects with auto-wired DI, SQLx support, and zero manual wiring. Formerly puerto-framework.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use async_trait::async_trait;
use uuid::Uuid;

use crate::domain::{{ snake }}::{errors::{{ pascal }}Error, model::{{ pascal }}};

#[derive(Debug, Clone)]
pub struct Get{{ pascal }}Params {
    pub id: Uuid,
}

#[async_trait]
pub trait Get{{ pascal }}UseCaseTrait: Send + Sync {
    async fn execute(&self, params: Get{{ pascal }}Params) -> Result<{{ pascal }}, {{ pascal }}Error>;
}