import { ethers } from "ethers"; import { CacheMapType, NegativeLayoutReason, NegativeStorageLayout, StorageLayoutCacheEventType, StorageLayoutCacheOptions, StorageLayoutKind, StoredStorageLayout, VerifiedStorageLayout } from "./types"; export declare const DEFAULT_CACHE_TTL_SECONDS: number; export declare const DEFAULT_NEGATIVE_CACHE_TTL_SECONDS: number; export declare const DEFAULT_CACHE_TIMEOUT_MS = 200; export declare const approvalCache: CacheMapType; export declare const balanceCache: CacheMapType; export declare const getStorageLayoutCacheKey: (kind: StorageLayoutKind, chainId: number, tokenAddress: string) => string; export declare const resolveCacheContext: (provider: ethers.providers.JsonRpcProvider, kind: StorageLayoutKind, tokenAddress: string, options?: StorageLayoutCacheOptions) => Promise<{ kind: StorageLayoutKind; chainId: number; tokenAddress: string; ttlSeconds: number; negativeTtlSeconds: number; timeoutMs: number; key: string; }>; export type StorageLayoutCacheContext = Awaited>; export declare const emitCacheEvent: (options: StorageLayoutCacheOptions, context: StorageLayoutCacheContext, type: StorageLayoutCacheEventType, reason?: NegativeLayoutReason) => void; export declare const isVerifiedStorageLayout: (value: unknown, ttlSeconds: number) => value is VerifiedStorageLayout; export declare const isNegativeStorageLayout: (value: unknown) => value is NegativeStorageLayout; export declare const isFreshNegativeStorageLayout: (value: unknown, negativeTtlSeconds: number) => value is NegativeStorageLayout; export declare const getExternalLayout: (options: StorageLayoutCacheOptions, context: StorageLayoutCacheContext) => Promise; export declare const setExternalLayout: (options: StorageLayoutCacheOptions, context: StorageLayoutCacheContext, value: StoredStorageLayout, ttlSeconds: number) => Promise; export declare const getLocalLayout: (cache: CacheMapType, key: string, ttlSeconds: number, negativeTtlSeconds?: number) => StoredStorageLayout | undefined; export declare const setLocalLayout: (cache: CacheMapType, key: string, value: VerifiedStorageLayout, ttlSeconds: number) => CacheMapType; export declare const setLocalNegative: (cache: CacheMapType, key: string, value: NegativeStorageLayout, negativeTtlSeconds: number) => CacheMapType; export declare const runVerifiedDiscovery: (key: string, discover: () => Promise) => Promise; export declare const getStorageAtLimited: (provider: ethers.providers.JsonRpcProvider, address: string, position: string) => Promise; //# sourceMappingURL=cache.d.ts.map