/**
 * Code Generator
 *
 * Orchestrates code generation using instance factories,
 * template engines, and configuration.
 */
import { TemplateEngineRegistry } from './engine-registry.js';
import type { ResolvedImplementation, TemplateContext } from '../types/index.js';
/**
 * Generated code output
 */
export interface GeneratedOutput {
    /** Generated code content */
    code: string;
    /** Output file path */
    filePath: string;
    /** Template that was used */
    templateName: string;
    /** Instance factory that was used */
    instanceFactory: string;
}
/**
 * Code generation options
 */
export interface CodeGenerationOptions {
    /** Base output directory */
    outputDir?: string;
    /** Template engine registry (defaults to global) */
    engineRegistry?: TemplateEngineRegistry;
    /** Dry run (don't write files, just return code) */
    dryRun?: boolean;
    /** Additional context to merge */
    additionalContext?: Record<string, any>;
}
/**
 * Code generator orchestrator
 */
export declare class CodeGenerator {
    private engineRegistry;
    private outputDir;
    constructor(options?: CodeGenerationOptions);
    /**
     * Generate code for a specific template
     */
    generateFromTemplate(resolved: ResolvedImplementation, templateName: string, context: Partial<TemplateContext>, options?: CodeGenerationOptions): Promise<GeneratedOutput>;
    /**
     * Generate code for all templates in an instance factory
     */
    generateAll(resolved: ResolvedImplementation, context: Partial<TemplateContext>, options?: CodeGenerationOptions): Promise<GeneratedOutput[]>;
    /**
     * Generate code for multiple resolved implementations
     */
    generateForDeployment(resolved: ResolvedImplementation[], context: Partial<TemplateContext>, options?: CodeGenerationOptions): Promise<Map<string, GeneratedOutput[]>>;
    /**
     * Resolve output path from template pattern
     *
     * Supports variable substitution:
     * - {controller} → context.controller.name
     * - {model} → context.model.name
     * - {service} → context.service.name
     * - {operation} → context.operation
     * - etc.
     */
    private resolveOutputPath;
    /**
     * Get a value from context, supporting nested properties
     */
    private getContextValue;
    /**
     * Get the template engine registry
     */
    getEngineRegistry(): TemplateEngineRegistry;
    /**
     * Set the output directory
     */
    setOutputDir(dir: string): void;
    /**
     * Get the output directory
     */
    getOutputDir(): string;
}
/**
 * Create a code generator with default configuration
 */
export declare function createCodeGenerator(options?: CodeGenerationOptions): CodeGenerator;
//# sourceMappingURL=code-generator.d.ts.map