import { logging } from '@angular-devkit/core'; import type { CategoryDescription } from '@o3r/core'; import { ComponentInformation } from './component-class-extractor'; import { ConfigurationInformationWrapper } from './component-config-extractor'; /** Output of a file parsing */ export interface FileParserOutput { /** Path to the file parsed */ file: string; /** Component extracted for the file */ component?: ComponentInformation; /** Configuration extracted for the file */ configuration?: ConfigurationInformationWrapper; } /** @inheritdoc */ export interface FileParserOutputComponent extends FileParserOutput { /** @inheritdoc */ component: ComponentInformation; } /** @inheritdoc */ export interface FileParserOutputConfiguration extends FileParserOutput { /** @inheritdoc */ configuration: ConfigurationInformationWrapper; } /** Output of the parser */ export interface ParserOutput { /** List of components parsed */ components: { [file: string]: FileParserOutputComponent; }; /** List of configuration parsed */ configurations: { [file: string]: FileParserOutputConfiguration; }; } /** * Component extractor parser. */ export declare class ComponentParser { private readonly libraryName; private readonly tsconfigPath; private readonly logger; private readonly strictMode; private readonly libraries; private readonly globalConfigCategories; private readonly globalConfigCategoriesMap; /** * Component extractor parser constructor * @param libraryName * @param tsconfigPath Path to the tsconfig defining the list of path to parse * @param logger Logger * @param strictMode * @param libraries * @param globalConfigCategories */ constructor(libraryName: string, tsconfigPath: string, logger: logging.LoggerApi, strictMode?: boolean, libraries?: string[], globalConfigCategories?: CategoryDescription[]); /** Get the list of patterns from tsconfig.json */ private getPatternsFromTsConfig; /** Get the list of file from tsconfig.json */ private getFilesFromTsConfig; /** * Extract a component of a given file * @param file Path to the file to extract the component from * @param source Typescript SourceFile node of the file */ private getComponent; /** * Extract a configuration of a given file * @param file Path to the file to extract the configuration from * @param source Typescript SourceFile node of the file * @param checker Typescript TypeChecker of the program */ private getConfiguration; /** * Extract the Components and Configurations implemented in each files from tsconfig * */ parse(): Promise; } //# sourceMappingURL=component-parser.d.ts.map