UNPKG

776 BTypeScriptView Raw
1import { DynamicModule, ForwardReference, Type } from '@nestjs/common/interfaces';
2import { ModuleTokenFactory } from './module-token-factory';
3export interface ModuleFactory {
4 type: Type<any>;
5 token: string;
6 dynamicMetadata?: Partial<DynamicModule>;
7}
8export declare class ModuleCompiler {
9 private readonly moduleTokenFactory;
10 constructor(moduleTokenFactory?: ModuleTokenFactory);
11 compile(metatype: Type<any> | DynamicModule | Promise<DynamicModule>): Promise<ModuleFactory>;
12 extractMetadata(metatype: Type<any> | ForwardReference | DynamicModule): {
13 type: Type<any>;
14 dynamicMetadata?: Partial<DynamicModule> | undefined;
15 };
16 isDynamicModule(module: Type<any> | DynamicModule | ForwardReference): module is DynamicModule;
17}