
typescript.interface.ts.vm Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vcd-bindings-generator Show documentation
Show all versions of vcd-bindings-generator Show documentation
Provides custom API bindings generation beyond what can be accomplished with xjc and OpenAPI
/*
* Copyright (c) ${year} VMware, Inc. All rights reserved.
*/
#foreach(${import} in ${class.imports})
import {${import.definition}} from "${import.module}";
#end
export interface ${class.name} #if(${class.parent})extends ${class.parent} #end{
#foreach(${field} in ${class.fields})
${field.name}#if(!${field.required})?#end: ${field.type};
#end
}
export namespace ${class.name} {
export class Fields #if(${class.parent})extends ${class.parent}.Fields #end{
#foreach(${field} in ${class.fields})
public static readonly $field.name.replaceAll("(.)(\p{Upper})", "$1_$2").toUpperCase(): string = "${field.name}";
#end
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy