import type { RushConfiguration } from './RushConfiguration';
import type { RushConfigurationProject } from './RushConfigurationProject';
import { CommonVersionsConfiguration } from './CommonVersionsConfiguration';
import { RepoStateFile } from '../logic/RepoStateFile';
import { PnpmOptionsConfiguration } from '../logic/pnpm/PnpmOptionsConfiguration';
/**
 * @internal
 */
export interface ISubspaceOptions {
    subspaceName: string;
    rushConfiguration: RushConfiguration;
    splitWorkspaceCompatibility: boolean;
}
/**
 * This represents the subspace configurations for a repository, based on the "subspaces.json"
 * configuration file.
 * @public
 */
export declare class Subspace {
    readonly subspaceName: string;
    private readonly _rushConfiguration;
    private readonly _projects;
    private readonly _splitWorkspaceCompatibility;
    private _commonVersionsConfiguration;
    private _detail;
    private _cachedPnpmOptions;
    private _cachedPnpmOptionsInitialized;
    constructor(options: ISubspaceOptions);
    /**
     * Returns the list of projects belonging to this subspace.
     * @beta
     */
    getProjects(): RushConfigurationProject[];
    /**
     * Returns the parsed contents of the pnpm-config.json config file.
     * @beta
     */
    getPnpmOptions(): PnpmOptionsConfiguration | undefined;
    private _ensureDetail;
    /**
     * Returns the full path of the folder containing this subspace's variant-dependent configuration files
     * such as `pnpm-lock.yaml`.
     *
     * Example (variants):               `C:\MyRepo\common\config\rush\variants\my-variant`
     * Example (variants and subspaces): `C:\MyRepo\common\config\subspaces\my-subspace\variants\my-variant`
     * Example (subspaces):              `C:\MyRepo\common\config\subspaces\my-subspace`
     * Example (neither):                `C:\MyRepo\common\config\rush`
     * @beta
     *
     * @remarks
     * The following files may be variant-dependent:
     * - Lockfiles: (i.e. - `pnpm-lock.yaml`, `npm-shrinkwrap.json`, `yarn.lock`, etc)
     * - 'common-versions.json'
     * - 'pnpmfile.js'/'.pnpmfile.cjs'
     */
    getVariantDependentSubspaceConfigFolderPath(variant: string | undefined): string;
    /**
     * Returns the full path of the folder containing this subspace's configuration files such as `pnpm-lock.yaml`.
     *
     * Example (subspaces feature enabled):   `C:\MyRepo\common\config\subspaces\my-subspace`
     * Example (subspaces feature disabled):  `C:\MyRepo\common\config\rush`
     * @beta
     */
    getSubspaceConfigFolderPath(): string;
    /**
     * Returns the full path of the folder containing this subspace's configuration files such as `pnpm-lock.yaml`.
     *
     * Example (subspaces feature enabled):   `C:\MyRepo\common\config\subspaces\my-subspace\pnpm-patches`
     * Example (subspaces feature disabled):  `C:\MyRepo\common\pnpm-patches`
     * @beta
     */
    getSubspacePnpmPatchesFolderPath(): string;
    /**
     * The full path of the folder where the subspace's node_modules and other temporary files will be stored.
     *
     * Example (subspaces feature enabled):   `C:\MyRepo\common\temp\subspaces\my-subspace`
     * Example (subspaces feature disabled):  `C:\MyRepo\common\temp`
     * @beta
     */
    getSubspaceTempFolderPath(): string;
    /**
     * Returns full path of the temporary shrinkwrap file for a specific subspace and returns the common workspace
     * shrinkwrap if no subspaceName is provided.
     * @remarks
     * This function takes the subspace name, and returns the full path for the subspace's shrinkwrap file.
     * This function also consults the deprecated option to allow for shrinkwraps to be stored under a package folder.
     * This shrinkwrap file is used during "rush install", and may be rewritten by the package manager during installation
     * This property merely reports the filename, the file itself may not actually exist.
     * example: `C:\MyRepo\common\<subspace_name>\pnpm-lock.yaml`
     * @beta
     */
    getTempShrinkwrapFilename(): string;
    /**
     * @deprecated - Use {@link Subspace.getTempShrinkwrapPreinstallFilePath} instead.
     */
    getTempShrinkwrapPreinstallFilename(subspaceName?: string | undefined): string;
    /**
     * The full path of a backup copy of tempShrinkwrapFilename. This backup copy is made
     * before installation begins, and can be compared to determine how the package manager
     * modified tempShrinkwrapFilename.
     * @remarks
     * This property merely reports the filename; the file itself may not actually exist.
     * Example: `C:\MyRepo\common\temp\npm-shrinkwrap-preinstall.json`
     * or `C:\MyRepo\common\temp\pnpm-lock-preinstall.yaml`
     * @beta
     */
    getTempShrinkwrapPreinstallFilePath(): string;
    /**
     * Gets the full path to the common-versions.json config file for this subspace.
     *
     * Example (subspaces feature enabled):   `C:\MyRepo\common\config\subspaces\my-subspace\common-versions.json`
     * Example (subspaces feature disabled):  `C:\MyRepo\common\config\rush\common-versions.json`
     * @beta
     */
    getCommonVersionsFilePath(variant?: string): string;
    /**
     * Gets the full path to the pnpm-config.json config file for this subspace.
     *
     * Example (subspaces feature enabled):   `C:\MyRepo\common\config\subspaces\my-subspace\pnpm-config.json`
     * Example (subspaces feature disabled):  `C:\MyRepo\common\config\rush\pnpm-config.json`
     * @beta
     */
    getPnpmConfigFilePath(): string;
    /**
     * Gets the settings from the common-versions.json config file.
     * @beta
     */
    getCommonVersions(variant?: string): CommonVersionsConfiguration;
    /**
     * Gets the ensureConsistentVersions property from the common-versions.json config file,
     * or from the rush.json file if it isn't defined in common-versions.json
     * @beta
     */
    shouldEnsureConsistentVersions(variant?: string): boolean;
    /**
     * Gets the path to the repo-state.json file.
     * @beta
     */
    getRepoStateFilePath(): string;
    /**
     * Gets the contents from the repo-state.json file.
     * @param subspaceName - The name of the subspace in use by the active command.
     * @beta
     */
    getRepoState(): RepoStateFile;
    /**
     * @deprecated - Use {@link Subspace.getCommittedShrinkwrapFilePath} instead.
     */
    getCommittedShrinkwrapFilename(): string;
    /**
     * Gets the committed shrinkwrap file name for a specific variant.
     * @param variant - The name of the current variant in use by the active command.
     * @beta
     */
    getCommittedShrinkwrapFilePath(variant?: string): string;
    /**
     * Gets the absolute path for "pnpmfile.js" for a specific subspace.
     * @param subspace - The name of the current subspace in use by the active command.
     * @remarks
     * The file path is returned even if PNPM is not configured as the package manager.
     * @beta
     */
    getPnpmfilePath(variant?: string): string;
    /**
     * Returns true if the specified project belongs to this subspace.
     * @beta
     */
    contains(project: RushConfigurationProject): boolean;
    /** @internal */
    _addProject(project: RushConfigurationProject): void;
    /**
     * Computes a hash of the PNPM catalog definitions for this subspace.
     * Returns undefined if no catalogs are defined.
     */
    getPnpmCatalogsHash(): string | undefined;
    /**
     * Returns hash value of injected dependencies in related package.json.
     * @beta
     */
    getPackageJsonInjectedDependenciesHash(variant?: string): string | undefined;
}
//# sourceMappingURL=Subspace.d.ts.map