Options
All
  • Public
  • Public/Protected
  • All
Menu

参数装饰器映射

Type parameters

Hierarchy

Index

Constructors

constructor

Properties

classMirror

classMirror: ClassMirror<any>

classMirror 当前参数所属ClassMirror

index

index: number

index 当前参数的下标

Readonly metadata

metadata: Set<T> = ...

metadata collection 元数据集合

methodMirror

methodMirror: null | MethodMirror<any, any>

methodMirror 当前参数所属MethodMirror 如果是构造函数的参数装饰器 则为null

propertyKey

propertyKey: null | string | symbol

propertyKey 当前参数的key名称 如果是构造函数的参数装饰器 则为null

target

target: Object

target Mirror映射的目标

Methods

getDesignParamType

  • getDesignParamType(): undefined | Function

getMetadata

Static createDecorator

Static reflect

  • reflect<T>(type: T, method: string | symbol, index: number, isStatic?: boolean): undefined | ParameterMirror<any>
  • reflect<T>(type: T, method: (...args: any[]) => any, index: number, isStatic?: boolean): undefined | ParameterMirror<any>
  • 使用函数名称查找映射数据

    Type parameters

    • T: Function

    Parameters

    • type: T
    • method: string | symbol
    • index: number
    • Optional isStatic: boolean

      使用此方法可以目标类上的函数所映射的ParameterMirror实例.

    Returns undefined | ParameterMirror<any>

  • 实现方法

    deprecated

    使用函数查找映射数据

    Type parameters

    • T: Function

    Parameters

    • type: T
    • method: (...args: any[]) => any
        • (...args: any[]): any
        • Parameters

          • Rest ...args: any[]

          Returns any

    • index: number
    • Optional isStatic: boolean

      使用此方法可以目标类上的函数所映射的ParameterMirror实例.

    Returns undefined | ParameterMirror<any>

Static reflectConstructor

  • reflectConstructor<P, T>(type: T, index: number): undefined | P