import { FakeFS, ZipFS, PortablePath, Filename } from '@yarnpkg/fslib'; import { Configuration } from './Configuration'; import { LocatorHash, Locator } from './types'; export declare type FetchFromCacheOptions = { checksums: Map; }; export declare class Cache { readonly configuration: Configuration; readonly cwd: PortablePath; readonly markedFiles: Set; readonly immutable: boolean; readonly check: boolean; private mutexes; static find(configuration: Configuration, { immutable, check }?: { immutable?: boolean; check?: boolean; }): Promise; constructor(cacheCwd: PortablePath, { configuration, immutable, check }: { configuration: Configuration; immutable?: boolean; check?: boolean; }); get mirrorCwd(): PortablePath | null; getLocatorFilename(locator: Locator): Filename; getLocatorPath(locator: Locator): PortablePath; getLocatorMirrorPath(locator: Locator): PortablePath | null; setup(): Promise; fetchPackageFromCache(locator: Locator, expectedChecksum: string | null, loader?: () => Promise): Promise<[FakeFS, () => void, string]>; private writeFileWithLock; }