Files
openapi-clean-arch-gen/templates/api.repository.contract.mustache
Blas Santome Ocampo 5ff88d8cf6 first commit
2026-03-23 09:35:15 +01:00

35 lines
914 B
Plaintext

{{#apiInfo}}
{{#apis}}
{{#operations}}
import { InjectionToken } from '@angular/core';
import { Observable } from 'rxjs';
{{#imports}}
import { {{classname}} } from '@/entities/models/{{classFilename}}.model';
{{/imports}}
/**
* {{classname}} Repository Contract
* Generated from OpenAPI tag: {{classname}}
*/
export interface {{classname}}Repository {
{{#operation}}
/**
* {{summary}}
{{#notes}}
* {{notes}}
{{/notes}}
{{#allParams}}
* @param {{paramName}} {{description}}
{{/allParams}}
*/
{{nickname}}({{#allParams}}{{paramName}}{{^required}}?{{/required}}: {{dataType}}{{^-last}}, {{/-last}}{{/allParams}}): Observable<{{#returnType}}{{returnType}}{{/returnType}}{{^returnType}}void{{/returnType}}>;
{{/operation}}
}
export const {{constantName}}_REPOSITORY = new InjectionToken<{{classname}}Repository>('{{constantName}}_REPOSITORY');
{{/operations}}
{{/apis}}
{{/apiInfo}}