Options
All
  • Public
  • Public/Protected
  • All
Menu

Class RouterExecutionContext

Hierarchy

  • RouterExecutionContext

Index

Constructors

constructor

Properties

Readonly applicationRef

applicationRef: HttpServer

Private Readonly contextUtils

contextUtils: ContextUtils = new ContextUtils()

Private Readonly guardsConsumer

guardsConsumer: GuardsConsumer

Private Readonly guardsContextCreator

guardsContextCreator: GuardsContextCreator

Private Readonly handlerMetadataStorage

handlerMetadataStorage: HandlerMetadataStorage<HandlerMetadata, any> = new HandlerMetadataStorage()

Private Readonly interceptorsConsumer

interceptorsConsumer: InterceptorsConsumer

Private Readonly interceptorsContextCreator

interceptorsContextCreator: InterceptorsContextCreator

Private Readonly paramsFactory

paramsFactory: IRouteParamsFactory

Private Readonly pipesConsumer

pipesConsumer: PipesConsumer

Private Readonly pipesContextCreator

pipesContextCreator: PipesContextCreator

Private Readonly responseController

responseController: RouterResponseController

Methods

create

  • create(instance: Controller, callback: (...args: any[]) => unknown, methodName: string, moduleKey: string, requestMethod: RequestMethod, contextId?: ContextId, inquirerId?: string): (Anonymous function)

createGuardsFn

  • createGuardsFn<TContext>(guards: CanActivate[], instance: Controller, callback: (...args: any[]) => any, contextType?: TContext): (args: any[]) => Promise<void> | null
  • Type parameters

    • TContext: string = ContextType

    Parameters

    • guards: CanActivate[]
    • instance: Controller
    • callback: (...args: any[]) => any
        • (...args: any[]): any
        • Parameters

          • Rest ...args: any[]

          Returns any

    • Optional contextType: TContext

    Returns (args: any[]) => Promise<void> | null

      • (args: any[]): Promise<void> | null
      • Parameters

        • args: any[]

        Returns Promise<void> | null

createHandleResponseFn

  • createHandleResponseFn(callback: (...args: unknown[]) => unknown, isResponseHandled: boolean, redirectResponse?: RedirectResponse, httpStatusCode?: number): HandleResponseFn

createPipesFn

  • createPipesFn(pipes: PipeTransform[], paramsOptions: (ParamProperties & { metatype?: any })[]): pipesFn

exchangeKeysForValues

  • exchangeKeysForValues(keys: string[], metadata: Record<number, RouteParamMetadata>, moduleContext: string, contextId?: ContextId, inquirerId?: string, contextFactory?: (args: unknown[]) => ExecutionContextHost): ParamProperties[]

getMetadata

getParamValue

  • getParamValue<T>(value: T, __namedParameters: { data: unknown; metatype: unknown; type: RouteParamtypes }, pipes: PipeTransform[]): Promise<unknown>

isPipeable

  • isPipeable(type: number | string): boolean

Private isResponseHandled

  • isResponseHandled(instance: Controller, methodName: string, paramsMetadata: ParamProperties[]): boolean

reflectHttpStatusCode

  • reflectHttpStatusCode(callback: (...args: unknown[]) => unknown): number

reflectRedirect

reflectRenderTemplate

  • reflectRenderTemplate(callback: (...args: unknown[]) => unknown): string

reflectResponseHeaders

  • reflectResponseHeaders(callback: (...args: unknown[]) => unknown): CustomHeader[]

reflectSse

  • reflectSse(callback: (...args: unknown[]) => unknown): string

Generated using TypeDoc