UNPKG

@trapi/metadata

Version:

Generate REST-API metadata scheme from TypeScript Decorators.

27 lines 958 B
import type { Node } from 'typescript'; import { DecoratorPropertyManager } from '../property-manager'; import type { DecoratorID } from '../constants'; import type { DecoratorConfig } from '../type'; import type { NodeDecorator } from '../../utils'; import type { DecoratorResolverMap } from './type'; export declare class DecoratorResolver { protected items: DecoratorConfig[]; protected map: DecoratorResolverMap; constructor(); /** * Try to find a matching representation for a given decorator type and decorators or node. * * @param id * @param data */ match<T extends `${DecoratorID}`>(id: T, data: NodeDecorator[] | Node): DecoratorPropertyManager<T> | undefined; apply(items: DecoratorConfig[]): void; applyPreset(name: string): Promise<void>; /** * Aggregate/group different annotation sources. * * @private */ private aggregate; } //# sourceMappingURL=module.d.ts.map