import type { LanguageAdapter } from './adapter.js'; /** Per-run registry of language adapters, indexed by id and file extension. */ export declare class LanguageRegistry { private readonly inner; private readonly byExtension; /** * Alias → canonical id index. Populated alongside the inner registry * during `register`. Lets `canonicalize` map an alias like `'c'` or * `'rs'` back to the registered adapter id (`'cpp'`, `'rust'`). */ private readonly aliasIndex; register(adapter: LanguageAdapter): void; private indexExtensions; private indexAliases; get(id: string): LanguageAdapter | undefined; forFile(filePath: string): LanguageAdapter | undefined; /** * Resolve a language id or alias to its canonical adapter id. * * - For a registered canonical id (e.g. `'cpp'`), returns the same id. * - For a registered alias (e.g. `'c'`, `'rs'`, `'golang'`, `'py'`), * returns the canonical id (`'cpp'`, `'rust'`, `'go'`, `'python'`). * - Returns `undefined` for unknown languages. * * Use this anywhere two pieces of code compare language strings — * scope-matching, target-language sets — so a config written with * `languages: ['c']` matches a check scoped to `cpp`. */ canonicalize(idOrAlias: string): string | undefined; list(): readonly LanguageAdapter[]; has(id: string): boolean; get size(): number; clear(): void; } //# sourceMappingURL=registry.d.ts.map