import { Storage, StorageKey, StorageKeyReturnType } from '@tezos-x/octez.connect-types'; export declare class IndexedDBStorage extends Storage { private readonly dbName; private readonly storeNames; private db; private isSupported; /** * @param dbName Name of the database. * @param storeNames An array of object store names to create in the database. * The first store in the array will be used as the default if none is specified. */ constructor(dbName?: string, storeNames?: string[]); private isIndexedDBSupported; private initDB; /** * Performs a transaction on the given object store. * @param mode Transaction mode. * @param storeName The name of the object store. * @param operation The operation to perform with the object store. */ private transaction; /** * Retrieves a value by key from the specified object store. * If no store is specified, the default (first in the list) is used. */ get(key: K, storeName?: string): Promise; get(key: string, storeName?: string): Promise; /** * Stores a key/value pair in the specified object store. */ set(key: K, value: StorageKeyReturnType[K], storeName?: string): Promise; set(key: string, value: string, storeName?: string): Promise; /** * Deletes an entry by key from the specified object store. */ delete(key: K, storeName?: string): Promise; delete(key: string, storeName?: string): Promise; /** * Retrieves all values from the specified object store. */ getAll(storeName?: string): Promise; /** * Retrieves all keys from the specified object store. */ getAllKeys(storeName?: string): Promise; /** * Clears all entries from the specified object store. */ clearStore(storeName?: string): Promise; getPrefixedKey(key: K): string; subscribeToStorageChanged(callback: (arg: { eventType: 'storageCleared' | 'entryModified'; key: string | null; oldValue: string | null; newValue: string | null; }) => {}): Promise; /** * Copies all key/value pairs from the source store into a target store. * @param targetDBName Name of the target database. * @param targetStoreName Name of the target object store. * @param skipKeys Keys to skip. * @param sourceStoreName (Optional) Source store name – defaults to the default store. */ fillStore(targetDBName: string, targetStoreName: string, skipKeys?: string[], sourceStoreName?: string): Promise; }