openapi_nexus_core/data/template_path_info.rs
1//! Template path information for file generation
2
3/// Information about a template and its output location
4#[derive(Debug, Clone, PartialEq, Eq)]
5pub struct TemplatePathInfo {
6 /// Path to the template file (e.g., "api/api_class.j2")
7 pub template_path: String,
8 /// Relative output path for the generated file (e.g., "apis/UserApi.ts")
9 pub output_relpath: String,
10}
11
12impl TemplatePathInfo {
13 /// Create a new template path info
14 pub fn new(template_path: impl Into<String>, output_relpath: impl Into<String>) -> Self {
15 Self {
16 template_path: template_path.into(),
17 output_relpath: output_relpath.into(),
18 }
19 }
20}