import { FileSystem, type NowConfig, type Telemetry } from '@servicenow/sdk-build-core'; import type { IConnector } from '../connector'; import { Project } from '../project'; import { templates, type Templates, type TemplateFile, type TemplateInfo, type TemplateLeaf } from './templates'; export interface TemplateQuery { label?: string; } export declare class ProjectFactory { private readonly fs; private readonly project?; private readonly telemetry; constructor(fs: FileSystem, telemetry?: Telemetry, project?: Project | undefined); getProjectTemplates(query?: TemplateQuery): (TemplateInfo & { id: keyof Templates; })[]; getPartialTemplates(query?: TemplateQuery): (TemplateInfo & { id: keyof Templates; })[]; private wouldConflict; getConfigurationTemplate(): (TemplateInfo & { id: keyof Templates; })[]; getOriginalFiles(workingDir: string): Record; createProjectFromApp(workingDir: string, scopeId: string, connector: IConnector, options: Partial>): Promise; createConfigurationProject(workingDir: string, connector: IConnector, scopeOptions: { scope: string | undefined; scopeId: string | undefined; }, options: Partial>): Promise; createProjectFromDirectory(workingDir: string, metadataDir: string, options: Partial>): Promise; private createProjectFromDirectory0; private findPackageJsonModule; createProject(workingDir: string, options: InitOptions): Project; private findSysAppXmlInformation; private findPluginPropertiesInfo; private getSysAppXML; private writeTemplates; static createNpmPackageName(appName: string): string; } export type InitOptions = Pick & { scopeId?: string; packageName: string; description: string; sdkVersion?: string; projectVersion?: string; templateId?: keyof Templates; metadataDir?: string | undefined; }; export declare const ProjectInitValidation: { validateInitOptions(options: InitOptions): string[]; validateAppName(name: string | undefined): string | void; validateScopeName(name: string | undefined, requiredPrefix?: string | undefined): string | void; validateNpmPackageName(name: string | undefined): string | void; }; export declare function wouldTemplateConflict(templateContent: string, existingContent: string, newContent: string): boolean; type RenderedTemplateFile = TemplateFile & { templateFile: TemplateFile; }; export declare const renderTemplates: (templates: TemplateFile[], data: Record, originalFiles: Record) => RenderedTemplateFile[]; export { templates }; export type { Templates, TemplateFile, TemplateInfo, TemplateLeaf };