import { RuntimeAgentService } from './runtime-agent.service.abstract.js'; import { SessionCommandHelper } from '../session/index.js'; import { type RuntimeType } from '../../constants.js'; /** * Factory for creating runtime-specific service instances. * Implements factory pattern to encapsulate runtime service creation logic. */ export declare class RuntimeServiceFactory { private static instanceCache; private static sessionHelperCache; private static logger; /** * Get or create a SessionCommandHelper, using lazy initialization. * This is the recommended way to get the helper for runtime service creation. */ private static getOrCreateSessionHelper; /** * Create a runtime service instance for the specified runtime type. * Automatically gets or creates the SessionCommandHelper. * * @param runtimeType - The type of runtime to create * @param _legacyParam - Ignored legacy parameter for backwards compatibility * @param projectRoot - The project root directory */ static create(runtimeType: RuntimeType, _legacyParam: unknown, projectRoot: string): RuntimeAgentService; /** * Create a runtime service without caching (for testing or special cases). * Automatically gets or creates the SessionCommandHelper. * * @param runtimeType - The type of runtime to create * @param _legacyParam - Ignored legacy parameter for backwards compatibility * @param projectRoot - The project root directory */ static createFresh(runtimeType: RuntimeType, _legacyParam: unknown, projectRoot: string): RuntimeAgentService; /** * Get available runtime types */ static getAvailableRuntimeTypes(): RuntimeType[]; /** * Clear cached instances (useful for testing or when configuration changes) */ static clearCache(): void; /** * Clear cached instance for a specific runtime type and project */ static clearCacheFor(runtimeType: RuntimeType, projectRoot: string): void; /** * Get cached instance count (useful for debugging/monitoring) */ static getCachedInstanceCount(): number; /** * Check if a runtime type is supported */ static isRuntimeTypeSupported(runtimeType: string): runtimeType is RuntimeType; /** * Set a custom session helper for testing purposes. * This allows injecting a mock SessionCommandHelper. * * @param sessionHelper - The session helper to use */ static setSessionHelperForTesting(sessionHelper: SessionCommandHelper | null): void; /** * Create a runtime service with an explicit session helper (for testing). * * @param runtimeType - The type of runtime to create * @param sessionHelper - The session helper to use * @param projectRoot - The project root directory */ static createWithHelper(runtimeType: RuntimeType, sessionHelper: SessionCommandHelper, projectRoot: string): RuntimeAgentService; } //# sourceMappingURL=runtime-service.factory.d.ts.map