1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
export default interface IStorage {
getName(): string;
generateKey(...args: string[]): string;
getPrefix(): string;
getBackend();
setItem(type: string, key: string, value: any): void;
setItem(key: string, value: any): void;
getItem(type: string, key: string): any;
getItem(key: string): any;
removeItem(type, key): void;
removeItem(key): void;
updateItem(type, key, variable, value): void;
updateItem(key, variable, value): void;
increment(key: string): void;
removeElement(type, key, name): void;
removeElement(key, name): void;
getItemsWithKeyPrefix(keyPrefix: string);
registerHook(eventName: string, func: (newValue: any, oldValue: any, key: string) => void);
removeHook(eventName: string, func?: (newValue: any, oldValue: any, key: string) => void);
removeAllHooks();
destroy();
}
|