/** * Simple Dependency Injection Container * * Provides basic DI functionality for managing application dependencies. * Supports singleton and factory registrations. */ type Factory = (container: Container) => T; export declare class Container { private registrations; /** * Register a singleton instance * @param key Unique identifier for the dependency * @param instance The singleton instance */ registerSingleton(key: string, instance: T): void; /** * Register a factory function that creates new instances * @param key Unique identifier for the dependency * @param factory Function that creates the instance */ registerFactory(key: string, factory: Factory): void; /** * Resolve a dependency by key * @param key Unique identifier for the dependency * @returns The resolved instance * @throws Error if dependency is not registered */ resolve(key: string): T; /** * Check if a dependency is registered * @param key Unique identifier for the dependency * @returns true if registered, false otherwise */ has(key: string): boolean; /** * Clear all registered dependencies */ clear(): void; /** * Get all registered keys * @returns Array of registered dependency keys */ getRegisteredKeys(): string[]; } /** * Default container instance for the application */ export declare const container: Container; /** * Container registration keys for core dependencies */ export declare const ContainerKeys: { readonly VariableManager: "IVariableManager"; readonly HttpFileParser: "IHttpFileParser"; readonly RequestExecutor: "IRequestExecutor"; readonly AssertionEngine: "IAssertionEngine"; readonly ScriptEngine: "IScriptEngine"; readonly EnvironmentManager: "EnvironmentManager"; readonly CookieJar: "CookieJar"; }; export {};