import type { StorageScope } from "./Storage.types"; export type StorageChangeOperation = "set" | "remove" | "clear" | "clearNamespace" | "clearGroup" | "setBatch" | "removeBatch" | "import" | "expire" | "rollback" | "external"; export type StorageChangeSource = "memory" | "native" | "web" | "external"; export type StorageKeyChangeEvent = { type: "key"; scope: StorageScope; key: string; oldValue: string | undefined; newValue: string | undefined; operation: StorageChangeOperation; source: StorageChangeSource; }; export type StorageBatchChangeEvent = { type: "batch"; scope: StorageScope; operation: StorageChangeOperation; source: StorageChangeSource; changes: StorageKeyChangeEvent[]; }; export type StorageChangeEvent = StorageKeyChangeEvent | StorageBatchChangeEvent; export type StorageEventListener = (event: StorageChangeEvent) => void; export declare class StorageEventRegistry { private readonly scopeListeners; private readonly keyListeners; private readonly prefixListeners; subscribe(scope: StorageScope, listener: StorageEventListener): () => void; hasListeners(scope: StorageScope): boolean; subscribeKey(scope: StorageScope, key: string, listener: StorageEventListener): () => void; subscribePrefix(scope: StorageScope, prefix: string, listener: StorageEventListener): () => void; emitKey(event: StorageKeyChangeEvent): void; emitBatch(event: StorageBatchChangeEvent): void; private emitToScope; private emitToKey; private emitToPrefixes; private emitBatchToPrefixes; } //# sourceMappingURL=storage-events.d.ts.map