/** * LicenseSeat SDK Cache Manager * Handles persistent storage of license data, offline licenses, and public keys. * @module cache */ /** * License Cache Manager * Manages persistent storage of license data using localStorage. */ export class LicenseCache { /** * Create a LicenseCache instance * @param {string} [prefix="licenseseat_"] - Prefix for all localStorage keys */ constructor(prefix?: string); /** @type {string} */ prefix: string; /** @type {string} */ publicKeyCacheKey: string; /** * Get the cached license data * @returns {import('./types.js').CachedLicense|null} Cached license or null if not found */ getLicense(): import("./types.js").CachedLicense | null; /** * Store license data in cache * @param {import('./types.js').CachedLicense} data - License data to cache * @returns {void} */ setLicense(data: import("./types.js").CachedLicense): void; /** * Update the validation data for the cached license * @param {import('./types.js').ValidationResult} validationData - Validation result to store * @returns {void} */ updateValidation(validationData: import("./types.js").ValidationResult): void; /** * Get the device ID from the cached license * @returns {string|null} Device ID or null if not found */ getDeviceId(): string | null; /** * Clear the cached license data * @returns {void} */ clearLicense(): void; /** * Get the cached offline token * @returns {import('./types.js').OfflineToken|null} Offline token or null if not found */ getOfflineToken(): import("./types.js").OfflineToken | null; /** * Store offline token data in cache * @param {import('./types.js').OfflineToken} data - Offline token to cache * @returns {void} */ setOfflineToken(data: import("./types.js").OfflineToken): void; /** * Clear the cached offline token * @returns {void} */ clearOfflineToken(): void; /** * Get a cached public key by key ID * @param {string} keyId - The key ID to look up * @returns {string|null} Base64-encoded public key or null if not found */ getPublicKey(keyId: string): string | null; /** * Store a public key in cache * @param {string} keyId - The key ID * @param {string} publicKeyB64 - Base64-encoded public key * @returns {void} */ setPublicKey(keyId: string, publicKeyB64: string): void; /** * Clear all LicenseSeat SDK data for this prefix * @returns {void} */ clear(): void; /** * Get the last seen timestamp (for clock tamper detection) * @returns {number|null} Unix timestamp in milliseconds or null if not set */ getLastSeenTimestamp(): number | null; /** * Store the last seen timestamp * @param {number} ts - Unix timestamp in milliseconds * @returns {void} */ setLastSeenTimestamp(ts: number): void; } //# sourceMappingURL=cache.d.ts.map