import type { CacheReadOptions, CacheStats } from "./shared-cache.js";
export type CacheAccessOptions = CacheReadOptions;
export type CacheKey = readonly (boolean | number | string | undefined)[] | boolean | number | string;
export declare enum CacheTag {
    CONTEXT = "context",
    CWD = "cwd",
    TS_CONFIG = "tsconfig"
}
export interface CacheMemoOptions extends CacheAccessOptions {
    paths?: readonly string[];
}
export interface CachedStoreState {
    data: SharedArrayBuffer;
    metadata: SharedArrayBuffer;
}
export declare class CachedStore {
    private static _cache;
    private static state;
    private static readonly textDecoder;
    private constructor();
    private static get cache();
    static attachSharedState(state: CachedStoreState): void;
    static getSharedState(): CachedStoreState;
    static get<Value = unknown>(key: string, options?: CacheAccessOptions): Value | undefined;
    static upsert<Value>(key: string, value: Value, options?: CacheAccessOptions): void;
    static getOrCreate<Value>(key: CacheKey, create: () => Promise<Value>, options?: CacheMemoOptions): Promise<Value>;
    static getOrCreate<Value>(key: CacheKey, create: () => Value, options?: CacheMemoOptions): Value;
    static isValid(key: CacheKey, options?: CacheMemoOptions): boolean;
    static readFile(filePath: string, options?: CacheAccessOptions): string;
    static has(key: string, options?: CacheAccessOptions): boolean;
    static hasFile(filePath: string, options?: CacheAccessOptions): boolean;
    static delete(key: string): boolean;
    static deleteFile(filePath: string): boolean;
    static invalidateTag(tag: string): void;
    static clear(): void;
    static getStats(): CacheStats;
    private static memoKey;
    private static fileDependencies;
    private static memoized;
    private static hashKey;
    private static fileStats;
}
//# sourceMappingURL=cached-store.d.ts.map