import type { LoadResult, LoaderFn } from '../types';
import type { ContentFs } from './content-fs';
import type { MarkdocError } from '../../types/index.js';
export declare class Cache {
    private fs;
    /**
     * Map of errors. Key is a cache key.
     */
    errors: Map<string, (Error | MarkdocError)[]>;
    /**
     * Two level map of cache records.
     * First level is a loaderKey, second level is a cache key.
     */
    private cache;
    /**
     * Two level map of access records.
     * First level is a loaderKey, second level is a cache key.
     */
    private accessRecords;
    private lifecycleContext;
    /**
     * Map of loader functions. Key is a loaderKey.
     */
    private loaders;
    constructor(fs: ContentFs);
    load<T>(resource: string, loaderObjOrName: string | {
        name: string;
        loader: LoaderFn<T>;
    }, depsArray?: string[]): Promise<LoadResult<T>>;
    cleanUpCache(): void;
    setLoaders(loaders: Record<string, LoaderFn>): void;
    private canUseCache;
    private wasChangedThisRun;
    private trackAccess;
}
//# sourceMappingURL=cache.d.ts.map