import { MapSet } from '../utils/index'; import { Type } from '../types'; import { IContainer } from '../IContainer'; import { ICacheManager } from '../ICacheManager'; /** * cache target. * * @export * @interface CacheTarget */ export interface CacheTarget { target: any; expires: number; } /** * cache manager. * * @export * @class CacheManager * @implements {ICacheManager} */ export declare class CacheManager implements ICacheManager { private container; cacheTokens: MapSet, CacheTarget>; constructor(container: IContainer); isChecking(): boolean; hasCache(targetType: Type): boolean; cache(targetType: Type, target: any, expires: number): void; get(targetType: Type, expires?: number): any; private timeout; checkExpires(): void; destroy(targetType: Type, target?: any): void; }