@nimbella/postman-api
Version:
Postman Collection to Nimbella Project: Take your APIs seamlessly into Serverless world with this API
27 lines (26 loc) • 1.12 kB
TypeScript
/// <reference types="node" />
import { Collection } from 'postman-collection';
import { SupportingItem, MethodStubParams, TestStubParams } from '../../utils';
export default class BaseGenerator {
language: string;
tmplPath: string;
methodStub: Buffer;
gitignoreStub: Buffer;
testStub: Buffer;
methodValidationStub: Buffer;
globalValidationStub: Buffer;
includeFile: Buffer;
tmplMethod: HandlebarsTemplateDelegate<MethodStubParams>;
tmplTest: HandlebarsTemplateDelegate<TestStubParams>;
tmplGitignore: HandlebarsTemplateDelegate<Collection>;
tmplMethodValidation: HandlebarsTemplateDelegate<string>;
tmplGlobalValidation: HandlebarsTemplateDelegate<string>;
tmplIncludeFile: HandlebarsTemplateDelegate<string[]>;
constructor(ext: string);
getMethodStub(item: any): string;
getTestStub(item: any, location: string): Promise<string>;
getMethodValidationStub(item: any): string;
getGlobalValidationStub(item: any): string;
getIncludeFile(files: string[]): SupportingItem;
getSupportingItems(collection: Collection): Array<SupportingItem>;
}