Interface Metadata

interface Metadata {
    apifix?: string;
    constructorName: string;
    cpath?: string;
    functionName: string | symbol;
    instance?: any;
    method?:
        | "GET"
        | "POST"
        | "PUT"
        | "DELETE"
        | "PATCH";
    mpath?: string;
}

Properties

apifix?: string

api前缀

constructorName: string

控制器对象名称

cpath?: string

控制器path,必传,不挂载控制器,可能为undefined

functionName: string | symbol

函数名称

instance?: any

控制器对象实例,不挂载控制器,可能为undefined

method?:
    | "GET"
    | "POST"
    | "PUT"
    | "DELETE"
    | "PATCH"

请求类型

mpath?: string

方法路径,可不传,默认值 = ''