تخطي إلى المحتوى

tsoa-next / tsoa-next / HapiTemplateService

الفئة: HapiTemplateService ​

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:45

Hapi- التنفيذ المحدد لعقد خدمات نموذج المسار المولد.

التذييلات ​

  • TemplateService<HapiApiHandlerParameters, HapiValidationArgsParameters, HapiReturnHandlerParameters>

Constructors ​

المؤسسة ​

ts
new HapiTemplateService(
   models, 
   config, 
   hapi): HapiTemplateService;

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:46

البارامترات ​

models ​

Models

config ​

AdditionalProps

hapi ​
boomify ​
isBoom ​

العودة ​

HapiTemplateService

تجاوزات ​

TemplateService.constructor

الممتلكات ​

config ​

ts
protected readonly config: AdditionalProps;

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:48

تجاوزات ​

TemplateService.config


models ​

ts
protected readonly models: Models;

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:47

تجاوزات ​

TemplateService.models


validationService ​

ts
protected validationService: ValidationService;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:10

Inherited from ​

TemplateService.validationService

الطرائق ​

apiHandler() ​

ts
apiHandler(params): Promise<unknown>;

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:57

يَدْفعُ عملَ المتحكمِ للظهورِ النشطِ.

البارامترات ​

params ​

HapiApiHandlerParameters

العودة ​

Promise<unknown>

تجاوزات ​

TemplateService.apiHandler


buildPromise() ​

ts
protected buildPromise(
   methodName, 
   controller, 
validatedArgs): Promise<unknown>;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:77

البارامترات ​

methodName ​

string

controller ​

object | Controller

validatedArgs ​

unknown[]

العودة ​

Promise<unknown>

Inherited from ​

TemplateService.buildPromise


getBodyProperty() ​

ts
protected getBodyProperty(
   body, 
   headers, 
   propertyName): unknown;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:62

البارامترات ​

body ​

unknown

headers ​

Record<string, unknown>

propertyName ​

string

العودة ​

unknown

Inherited from ​

TemplateService.getBodyProperty


getValidatedArgs() ​

ts
getValidatedArgs(params): unknown[];

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:88

ويقيم ويطبيع الحجج المستقاة من الطلب.

البارامترات ​

params ​

HapiValidationArgsParameters

العودة ​

unknown[]

تجاوزات ​

TemplateService.getValidatedArgs


isController() ​

ts
protected isController(object): object is Controller;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:28

البارامترات ​

object ​

object | Controller

العودة ​

object is Controller

Inherited from ​

TemplateService.isController


isRecord() ​

ts
protected isRecord(value): value is Record<string, unknown>;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:73

البارامترات ​

value ​

unknown

العودة ​

value is Record<string, unknown>

Inherited from ​

TemplateService.isRecord


normalizeRequestBody() ​

ts
protected normalizeRequestBody(body, headers): unknown;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:54

البارامترات ​

body ​

unknown

headers ​

Record<string, unknown>

العودة ​

unknown

Inherited from ​

TemplateService.normalizeRequestBody


requestHasBody() ​

ts
protected requestHasBody(headers): boolean;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:32

البارامترات ​

headers ​

Record<string, unknown>

العودة ​

boolean

Inherited from ​

TemplateService.requestHasBody


requestUsesTransferEncoding() ​

ts
protected requestUsesTransferEncoding(headers): boolean;

محددة في: packages/runtime/src/routeGeneration/templates/templateService.ts:50

البارامترات ​

headers ​

Record<string, unknown>

العودة ​

boolean

Inherited from ​

TemplateService.requestUsesTransferEncoding


returnHandler() ​

ts
protected returnHandler(params): unknown;

محددة في: packages/runtime/src/routeGeneration/templates/hapi/hapiTemplateService.ts:148

يكتب المتحكم يعود إلى العمل

البارامترات ​

params ​

HapiReturnHandlerParameters

العودة ​

unknown

تجاوزات ​

TemplateService.returnHandler

Contributors

No contributors

Changelog

No recent changes

توليد OpenAPI وتوليد المسارات والتحقق وقت التشغيل مع اعتماد TypeScript أولاً.