/**
 * Lazy Loading Generator Registry
 * Loads generators on-demand to improve startup performance
 */
import { Generator } from './types';
import { GeneratorRegistry } from './generator-registry';
/**
 * Generator factory function for lazy initialization
 */
type GeneratorFactory = () => Generator | Promise<Generator>;
/**
 * Generator loader configuration
 */
interface GeneratorLoader {
    id: string;
    category: 'frontend' | 'backend' | 'database' | 'test' | 'documentation' | 'cli' | 'custom';
    factory: GeneratorFactory;
    loaded: boolean;
    instance?: Generator;
}
/**
 * Lazy-loading wrapper for GeneratorRegistry
 * Only loads generators when they're actually needed
 */
export declare class LazyGeneratorRegistry {
    private registry;
    private loaders;
    private loadTimes;
    constructor(baseRegistry: GeneratorRegistry);
    /**
     * Register a generator with lazy loading
     */
    registerLazy(id: string, category: GeneratorLoader['category'], factory: GeneratorFactory): void;
    /**
     * Get a generator by ID, loading it if necessary
     */
    getGenerator(id: string): Promise<Generator | undefined>;
    /**
     * Get frontend generator (lazy load)
     */
    getFrontendGenerator(framework: string): Promise<Generator | undefined>;
    /**
     * Get backend generator (lazy load)
     */
    getBackendGenerator(language?: string, framework?: string): Promise<Generator | undefined>;
    /**
     * Get database generator (lazy load)
     */
    getDatabaseGenerator(technology: string): Promise<Generator | undefined>;
    /**
     * Get test generator (lazy load)
     */
    getTestGenerator(framework: string): Promise<Generator | undefined>;
    /**
     * Get all custom generators (lazy load all)
     */
    getCustomGenerators(): Promise<Generator[]>;
    /**
     * Preload specific generators (for performance-critical paths)
     */
    preload(ids: string[]): Promise<void>;
    /**
     * Preload all generators (useful for warming up)
     */
    preloadAll(): Promise<void>;
    /**
     * Load a specific generator
     */
    private loadGenerator;
    /**
     * Check if generator matches backend criteria
     */
    private matchesBackendCriteria;
    /**
     * Get loading statistics
     */
    getLoadStats(): {
        total: number;
        loaded: number;
        pending: number;
        totalLoadTime: number;
        averageLoadTime: number;
        loadTimes: Map<string, number>;
    };
    /**
     * Check if a generator is loaded
     */
    isLoaded(id: string): boolean;
    /**
     * Get list of all registered generator IDs
     */
    listGeneratorIds(): string[];
    /**
     * Get list of loaded generator IDs
     */
    listLoadedGeneratorIds(): string[];
    /**
     * Get list of pending generator IDs
     */
    listPendingGeneratorIds(): string[];
    /**
     * Get the underlying base registry (for compatibility)
     */
    getBaseRegistry(): GeneratorRegistry;
}
/**
 * Create lazy registry with standard generators
 */
export declare function createLazyRegistry(baseRegistry: GeneratorRegistry): LazyGeneratorRegistry;
export {};
//# sourceMappingURL=lazy-registry.d.ts.map