/** * Local Project Discovery * * Handles discovery and caching of local project paths for the dev server. * Supports finding projects in standard directories (data/projects, projects). * * @module server/runtime-handler/local-project-discovery */ import type { RuntimeAdapter } from "../../platform/adapters/base.js"; import { LRUCache } from "../../utils/lru-wrapper.js"; /** * Injectable cache container for project discovery state. * * Wraps both the project-path cache (slug → absolute path) and the * adapter cache (project dir → RuntimeAdapter) so that callers — especially * tests — can supply an isolated instance instead of sharing global state. */ export declare class ProjectDiscoveryCache { /** Cache of discovered local project paths by slug */ readonly projects: LRUCache; /** Cache of local adapters by project directory */ readonly adapters: LRUCache; constructor(opts?: { maxProjects?: number; maxAdapters?: number; }); /** Clear both caches */ clear(): void; } /** Default module-level cache instance (backward-compatible singleton) */ export declare const defaultDiscoveryCache: ProjectDiscoveryCache; /** Standard directories to search for local projects */ export declare const standardProjectDirs: string[]; /** * Find the local filesystem path for a project by slug. * * @param slug - The project slug to find * @param adapter - The runtime adapter to use for filesystem operations * @param headerPath - Optional path from x-project-path header (takes precedence) * @param cache - Optional cache instance (defaults to module-level singleton) * @returns The absolute path to the project, or undefined if not found */ export declare function findLocalProjectPath(slug: string, adapter: RuntimeAdapter, headerPath?: string, cache?: ProjectDiscoveryCache): Promise; //# sourceMappingURL=local-project-discovery.d.ts.map