/**
 * TypeScript Template Engine
 *
 * Executes TypeScript generator functions to produce code.
 * This is the primary template engine for Phase 1.
 */
import type { TemplateEngine, CodeTemplate, TemplateContext, ValidationResult } from '../types/index.js';
/**
 * Generator function signature
 */
export type GeneratorFunction = (context: TemplateContext) => string | Promise<string>;
/**
 * Validator function signature
 */
export type ValidatorFunction = (code: string, context: TemplateContext) => ValidationResult | Promise<ValidationResult>;
/**
 * Post-processor function signature
 */
export type PostProcessorFunction = (code: string, context: TemplateContext) => string | Promise<string>;
/**
 * Template engine error
 */
export declare class TemplateEngineError extends Error {
    templateName?: string;
    cause?: Error;
    constructor(message: string, templateName?: string, cause?: Error);
}
/**
 * TypeScript template engine implementation
 */
export declare class TypeScriptTemplateEngine implements TemplateEngine {
    private generatorCache;
    private validatorCache;
    private postProcessorCache;
    private baseDir;
    private tsxRegistered;
    constructor(options?: {
        baseDir?: string;
        enableCache?: boolean;
    });
    /**
     * Register tsx to enable TypeScript imports (lazy-loaded)
     */
    private ensureTsxRegistered;
    /**
     * Render a template with the given context
     */
    render(template: CodeTemplate, context: TemplateContext): Promise<string>;
    /**
     * Load a generator function from a file path
     */
    private loadGenerator;
    /**
     * Load a validator function from a file path
     */
    private loadValidator;
    /**
     * Load a post-processor function from a file path
     */
    private loadPostProcessor;
    /**
     * Clear all caches
     */
    clearCache(): void;
    /**
     * Get cache statistics
     */
    getCacheStats(): {
        generators: number;
        validators: number;
        postProcessors: number;
    };
}
//# sourceMappingURL=typescript-engine.d.ts.map