import { Duration } from '@salesforce/kit'; import { JsonMap, Nullable } from '@salesforce/ts-types'; import { ConfigFile } from './configFile'; /** * A Time To Live configuration file where each entry is timestamped and removed once the TTL has expired. * * @example * ``` * import { Duration } from '@salesforce/kit'; * const config = await TTLConfig.create({ * isGlobal: false, * ttl: Duration.days(1) * }); * ``` */ export declare class TTLConfig extends ConfigFile> { set(key: string, value: Partial>): void; getLatestEntry(): Nullable<[string, TTLConfig.Entry

]>; getLatestKey(): Nullable; isExpired(dateTime: number, value: P & { timestamp: string; }): boolean; protected init(): Promise; private timestamp; } export declare namespace TTLConfig { type Options = ConfigFile.Options & { ttl: Duration; }; type Entry = T & { timestamp: string; }; type Contents = Record>; }