/** * Standard cache interface that allows for the storage (store) and retrieval (lookup) of * key-value pairs with false negatives: The lookup of a key might return undefined even * if the key was previously stored, but if the lookup does return a defined value, the value is * guaranteed to be that of the most recent store for the key. */ export interface Cache { /** * Store a key-value pair in the cache. */ store(key: KeyType, value: ValueType): void; /** * Lookup the value for a specified key with possible false negatives. See comment * above the interface definition. */ lookup(key: KeyType): ValueType | undefined; } /** * Factory method to construct a cache. */ export declare function getCache(cacheSize: number): Cache;