/**
 * Server Manager
 *
 * Manages server plugin states, scanning, and comparison
 * between production and test environments.
 */
import { EventEmitter } from 'node:events';
import { type ScanProgress, type ScanProgressCallback, type ScannedPlugin, type ServerPluginState, ServerType, type VersionDifference } from './types/index.js';
/**
 * Server Manager events
 */
export interface ServerManagerEvents {
    scanStart: [serverType: ServerType];
    scanProgress: [serverType: ServerType, progress: ScanProgress];
    scanComplete: [serverType: ServerType, state: ServerPluginState];
    scanError: [serverType: ServerType, error: Error];
}
/**
 * Server Manager class
 */
export declare class ServerManager extends EventEmitter<ServerManagerEvents> {
    private productionPath;
    private testPath;
    private dataDir;
    private productionState;
    private testState;
    constructor(productionPath: string, testPath: string, dataDir?: string);
    /**
     * Get the plugins path for a server type
     */
    getPluginsPath(serverType: ServerType): string;
    /**
     * Get the state cache file path for a server type
     */
    private getStatePath;
    /**
     * Scan a server's plugins directory
     */
    scan(serverType: ServerType, onProgress?: ScanProgressCallback): Promise<ServerPluginState>;
    /**
     * Scan both servers
     */
    scanBoth(onProgress?: (serverType: ServerType, progress: ScanProgress) => void): Promise<{
        production: ServerPluginState;
        test: ServerPluginState;
    }>;
    /**
     * Save server state to cache file
     */
    private saveState;
    /**
     * Load server state from cache file
     */
    loadState(serverType: ServerType): Promise<ServerPluginState | null>;
    /**
     * Get current state for a server (from memory)
     */
    getState(serverType: ServerType): ServerPluginState | null;
    /**
     * Get production state
     */
    get production(): ServerPluginState | null;
    /**
     * Get test state
     */
    get test(): ServerPluginState | null;
    /**
     * Find a plugin on a server by name
     */
    findPlugin(serverType: ServerType, name: string): ScannedPlugin | undefined;
    /**
     * Get plugin version on a server
     */
    getPluginVersion(serverType: ServerType, name: string): string | null;
    /**
     * Check if a plugin exists on a server
     */
    hasPlugin(serverType: ServerType, name: string): boolean;
    /**
     * Compare plugin versions between production and test servers
     */
    compareServers(): VersionDifference[];
    /**
     * Get plugins that are only on production
     */
    getProductionOnlyPlugins(): ScannedPlugin[];
    /**
     * Get plugins that are only on test
     */
    getTestOnlyPlugins(): ScannedPlugin[];
    /**
     * Get plugins with version mismatches
     */
    getVersionMismatches(): Array<{
        name: string;
        production: string;
        test: string;
        productionNewer: boolean;
    }>;
    /**
     * Get summary statistics
     */
    getSummary(): {
        production: {
            count: number;
            valid: boolean;
        };
        test: {
            count: number;
            valid: boolean;
        };
        differences: number;
        productionOnly: number;
        testOnly: number;
    };
    /**
     * Create a new ServerManager and optionally load cached states
     */
    static create(productionPath: string, testPath: string, dataDir?: string, loadCached?: boolean): Promise<ServerManager>;
}
//# sourceMappingURL=server-manager.d.ts.map