import type { SurfaceMode } from "../program/types.js";
import { type Diagnostic } from "../types/diagnostic.js";
import { type Result } from "../types/result.js";
export type ResolvedSourcePackageImport = {
    readonly packageName: string;
    readonly packageRoot: string;
    readonly resolvedPath: string;
};
export type ParsedPackageSpecifier = {
    readonly packageName: string;
    readonly subpath: string | undefined;
};
export type ResolvedInstalledPackageImport = {
    readonly packageName: string;
    readonly packageRoot: string;
    readonly resolvedPath: string;
    readonly isDeclarationFile: boolean;
};
export declare const findInstalledPackageRoot: (packageName: string, containingFile: string) => string | undefined;
export declare const findContainingSourcePackageRoot: (filePath: string) => string | undefined;
export declare const isPathWithinBoundary: (filePath: string, boundary: string) => boolean;
export declare const getLocalResolutionBoundary: (containingFile: string, defaultSourceRoot: string) => string;
export declare const parsePackageSpecifier: (importSpecifier: string) => ParsedPackageSpecifier | undefined;
export declare const resolveInstalledPackageImportFromPackageRoot: (importSpecifier: string, packageRoot: string) => Result<ResolvedInstalledPackageImport | null, Diagnostic>;
export declare const resolveInstalledPackageImport: (importSpecifier: string, containingFile: string) => Result<ResolvedInstalledPackageImport | null, Diagnostic>;
export declare const resolveSourcePackageImportFromPackageRoot: (importSpecifier: string, packageRoot: string, activeSurface: SurfaceMode | undefined, projectRoot: string) => Result<ResolvedSourcePackageImport | null, Diagnostic>;
export declare const resolveSourcePackageAliasTarget: (aliasTarget: string, packageRoot: string, activeSurface: SurfaceMode | undefined, projectRoot: string) => Result<ResolvedSourcePackageImport | null, Diagnostic>;
export declare const resolveSourcePackageImport: (importSpecifier: string, containingFile: string, activeSurface: SurfaceMode | undefined, projectRoot: string) => Result<ResolvedSourcePackageImport | null, Diagnostic>;
export declare const __resetSourcePackageResolutionCachesForTests: () => void;
//# sourceMappingURL=source-package-resolution.d.ts.map