/**
 * Binding Registry - runtime registry of all loaded bindings
 * Supports simple (global/module) and hierarchical (namespace/type/member) formats
 *
 * This file is a thin facade. Heavy logic lives in:
 *   - binding-registry-resolution.ts  (member & extension-method resolution)
 *   - binding-registry-loading.ts     (addBindings ingestion)
 */
import type { MemberBinding, TypeBinding, NamespaceBinding, SimpleBindingDescriptor, TsbindgenExport, BindingFile } from "./binding-types.js";
export declare const simpleBindingContributesTypeIdentity: (descriptor: SimpleBindingDescriptor) => boolean;
/**
 * Registry of all loaded bindings
 * Supports simple (global/module) and hierarchical (namespace/type/member) formats
 */
export declare class BindingRegistry {
    private readonly loadedBindingFiles;
    private readonly sourceOwnedTypeAliases;
    private readonly simpleBindings;
    private readonly simpleGlobalBindings;
    private readonly simpleModuleBindings;
    private readonly namespaces;
    private readonly types;
    private readonly typeLookupAliasMap;
    private readonly members;
    private readonly memberOverloads;
    private readonly clrMemberOverloads;
    private readonly clrTypeNamesByAlias;
    private readonly tsbindgenExports;
    private readonly tsSupertypes;
    private readonly tsBaseTypes;
    private readonly clrTypeNames;
    /**
     * Extension method index for instance-style calls.
     *
     * Keyed by:
     * - declaring namespace key (CLR namespace with '.' replaced by '_', e.g. "System_Linq")
     * - receiver TS type name (e.g. "IEnumerable_1")
     * - method TS name (e.g. "where")
     *
     * Values are one or more candidates (overloads share the same target).
     */
    private readonly extensionMethods;
    /** Snapshot of mutable state for use by extracted pure resolution functions. */
    private get state();
    /**
     * Load a binding manifest file and add its bindings to the registry
     * Supports simple, full, and tsbindgen formats
     */
    addBindings(_filePath: string, manifest: BindingFile): void;
    /**
     * Look up a simple global/module binding
     */
    getExactBinding(name: string): SimpleBindingDescriptor | undefined;
    getExactBindingByKind(name: string, kind: SimpleBindingDescriptor["kind"]): SimpleBindingDescriptor | undefined;
    /**
     * Look up a simple global/module binding by exact authored name.
     */
    getBinding(name: string): SimpleBindingDescriptor | undefined;
    getBindingByKind(name: string, kind: SimpleBindingDescriptor["kind"]): SimpleBindingDescriptor | undefined;
    hasSourceOwnedTypeAlias(typeAlias: string): boolean;
    /**
     * Look up a namespace binding by TS alias
     */
    getNamespace(tsAlias: string): NamespaceBinding | undefined;
    /**
     * Look up a type binding by TS alias
     */
    getType(tsAlias: string): TypeBinding | undefined;
    /**
     * Check whether a CLR type name exists in loaded bindings.
     */
    hasClrTypeName(clrTypeName: string): boolean;
    /**
     * Look up a member binding by TS type alias and member alias
     */
    getMember(typeAlias: string, memberAlias: string): MemberBinding | undefined;
    /**
     * Look up all member bindings for a TS type alias + member alias.
     *
     * IMPORTANT: Methods can be overloaded, and overloads can differ in ref/out/in
     * modifiers (tsbindgen provides these via `parameterModifiers`). This accessor
     * preserves overload sets so the call converter can select the correct one.
     */
    getMemberOverloads(typeAlias: string, memberAlias: string, preferredClrOwner?: string): readonly MemberBinding[] | undefined;
    /**
     * Look up all member bindings for a CLR member target.
     *
     * Keyed by declaring assembly, CLR type, and CLR member name.
     */
    getClrMemberOverloads(assembly: string, clrType: string, clrMember: string): readonly MemberBinding[] | undefined;
    /**
     * Resolve an extension method binding target by extension interface name.
     *
     * @param extensionInterfaceName - e.g. "__Ext_System_Linq_IEnumerable_1"
     * @param methodTsName - e.g. "where"
     */
    resolveExtensionMethod(extensionInterfaceName: string, methodTsName: string, callArgumentCount?: number): MemberBinding | undefined;
    /**
     * Resolve an extension method binding target by explicit (namespaceKey, receiverTypeName).
     *
     * Used when extension methods are emitted as method-table members with explicit `this:`
     * receiver constraints (the declaring interface name no longer encodes the receiver type).
     */
    resolveExtensionMethodByKey(namespaceKey: string, receiverTypeName: string, methodTsName: string, callArgumentCount?: number): MemberBinding | undefined;
    /**
     * Look up a tsbindgen flattened named export by CLR namespace + export name.
     */
    getTsbindgenExport(namespace: string, exportName: string): TsbindgenExport | undefined;
    /**
     * Get all loaded simple bindings
     */
    getAllBindings(): readonly [string, SimpleBindingDescriptor][];
    isTypeOrSubtype(typeAlias: string, superAlias: string): boolean;
    /**
     * Get all loaded namespaces
     */
    getAllNamespaces(): readonly NamespaceBinding[];
    /**
     * Get a copy of the types map for passing to the emitter.
     * Returns a new Map to ensure immutability - callers cannot modify the registry.
     */
    getTypesMap(): ReadonlyMap<string, TypeBinding>;
    /**
     * Get the type map used by the emitter.
     *
     * This includes:
     * - hierarchical tsbindgen/full-manifest types
     * - simple global bindings that are type-like (e.g. Error, Date, Uint8Array)
     *
     * Expression lowering still uses the full binding registry. This view exists so
     * type emission can resolve ambient global constructors/types that are authored
     * via simple bindings instead of hierarchical type manifests.
     */
    getEmitterTypeMap(): ReadonlyMap<string, TypeBinding>;
    /**
     * Clear all loaded bindings
     */
    clear(): void;
}
//# sourceMappingURL=binding-registry.d.ts.map