devsite/node_modules/liquidjs/dist/cache/lru.d.ts

15 lines
391 B
TypeScript
Raw Permalink Normal View History

2024-07-08 01:49:38 +00:00
import { Cache } from './cache';
export declare class LRU<T> implements Cache<T> {
limit: number;
size: number;
private cache;
private head;
private tail;
constructor(limit: number, size?: number);
write(key: string, value: T): void;
read(key: string): T | undefined;
remove(key: string): void;
clear(): void;
private ensureLimit;
}