@btc-vision/bsi-common
Version:
Common library for OP_NET.
9 lines (8 loc) • 327 B
TypeScript
import { ICacheStrategy } from './interfaces/ICacheStrategy.js';
export declare class NodeCacheStrategy<T> implements ICacheStrategy<T> {
private readonly maxItems;
private cache;
constructor(maxItems?: number);
get(key: string): Promise<T | undefined>;
set(key: string, value: T, ttl?: number): boolean;
}