import type { GetEntityCache } from './entitiesCache.js'; import { EndpointsCache } from './types.js'; import type { KeyFn } from './WeakDependencyMap.js'; import type Cache from '../denormalize/cache.js'; import type { INVALID } from '../denormalize/symbol.js'; import type { EntityInterface, EntityPath } from '../interface.js'; import type { DenormGetEntity } from './types.js'; export default class GlobalCache implements Cache { private dependencies; private cycleCache; private cycleIndex; private localCache; private _getCache; private _getEntity; private _resultCache; private _args; /** Set true once `argsKey` is called for this denormalize frame. Gates * function-stripping fast paths in `paths()` / `getResults()`. */ private _hasArgsKey; constructor(getEntity: DenormGetEntity, getCache: GetEntityCache, resultCache: EndpointsCache, args?: readonly any[]); /** Records `fn(args)` as a string-keyed dependency for the surrounding * entity-cache frame and returns the value. The function reference is the * cache path key (must be referentially stable); `set` later re-evaluates * the function with the same `args` to derive the bucket key — keeps the * Dep shape monomorphic with entity-style deps (`{path, entity}`). */ argsKey(fn: KeyFn): string | undefined; getEntity(pk: string, schema: EntityInterface, entity: any, computeValue: (localCacheKey: Map) => void): object | undefined | typeof INVALID; private getOrCreateLocalCache; private getOrCreateCycleCache; /** Cache varies based on input (=== aka reference) */ getResults(input: any, cachable: boolean, computeValue: () => any): { data: any; paths: EntityPath[]; }; /** Materialize the EntityPath subscription list. Function-typed * (`argsKey`) deps are not subscribable entities and are filtered out. */ protected paths(): EntityPath[]; } //# sourceMappingURL=globalCache.d.ts.map