@rxap/ngx-memory 19.0.1-dev.2 → 19.0.1-dev.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/README.md +24 -25
- package/compodoc/changelog.html +6 -0
- package/compodoc/dependencies.html +1 -1
- package/compodoc/index.html +26 -17
- package/compodoc/js/search/search_index.js +2 -2
- package/compodoc/properties.html +4 -1
- package/docs/documentation.json +458 -387
- package/docs/html/assets/hierarchy.js +1 -0
- package/docs/{assets → html/assets}/highlight.css +13 -6
- package/docs/html/assets/icons.js +18 -0
- package/docs/html/assets/icons.svg +1 -0
- package/docs/{assets → html/assets}/main.js +5 -4
- package/docs/html/assets/navigation.js +1 -0
- package/docs/html/assets/search.js +1 -0
- package/docs/html/assets/style.css +1611 -0
- package/docs/html/classes/EphemeralStorageService.html +13 -0
- package/docs/html/classes/LocalStorageService.html +13 -0
- package/docs/html/classes/MockStorage.html +25 -0
- package/docs/html/classes/SessionStorageService.html +13 -0
- package/docs/html/classes/StorageService.html +13 -0
- package/docs/html/functions/LocalStorage.html +5 -0
- package/docs/html/functions/SessionStorage.html +5 -0
- package/docs/html/functions/StorageGet.html +1 -0
- package/docs/html/functions/StorageHas.html +1 -0
- package/docs/html/functions/StorageKey.html +1 -0
- package/docs/html/functions/StorageRemove.html +1 -0
- package/docs/html/functions/StorageSet.html +1 -0
- package/docs/html/functions/WebStorage.html +1 -0
- package/docs/html/functions/getExpired.html +1 -0
- package/docs/html/functions/stringify.html +1 -0
- package/docs/html/hierarchy.html +1 -0
- package/docs/html/index.html +33 -0
- package/docs/html/modules.html +1 -0
- package/docs/html/types/ExpiredUnit.html +9 -0
- package/docs/html/variables/isBrowser.html +4 -0
- package/docs/markdown/README.md +37 -0
- package/docs/markdown/classes/EphemeralStorageService.md +151 -0
- package/docs/markdown/classes/LocalStorageService.md +151 -0
- package/docs/markdown/classes/MockStorage.md +189 -0
- package/docs/markdown/classes/SessionStorageService.md +151 -0
- package/docs/markdown/classes/StorageService.md +135 -0
- package/docs/markdown/functions/LocalStorage.md +51 -0
- package/docs/markdown/functions/SessionStorage.md +51 -0
- package/docs/markdown/functions/StorageGet.md +25 -0
- package/docs/markdown/functions/StorageHas.md +25 -0
- package/docs/markdown/functions/StorageKey.md +25 -0
- package/docs/markdown/functions/StorageRemove.md +25 -0
- package/docs/markdown/functions/StorageSet.md +37 -0
- package/docs/markdown/functions/WebStorage.md +49 -0
- package/docs/markdown/functions/getExpired.md +25 -0
- package/docs/markdown/functions/stringify.md +21 -0
- package/docs/markdown/globals.md +34 -0
- package/docs/markdown/type-aliases/ExpiredUnit.md +20 -0
- package/docs/markdown/variables/isBrowser.md +15 -0
- package/docs/wiki/Class.EphemeralStorageService.md +147 -0
- package/docs/wiki/Class.LocalStorageService.md +147 -0
- package/docs/wiki/Class.MockStorage.md +185 -0
- package/docs/wiki/Class.SessionStorageService.md +147 -0
- package/docs/wiki/Class.StorageService.md +131 -0
- package/docs/wiki/Function.LocalStorage.md +47 -0
- package/docs/wiki/Function.SessionStorage.md +47 -0
- package/docs/wiki/Function.StorageGet.md +21 -0
- package/docs/wiki/Function.StorageHas.md +21 -0
- package/docs/wiki/Function.StorageKey.md +21 -0
- package/docs/wiki/Function.StorageRemove.md +21 -0
- package/docs/wiki/Function.StorageSet.md +33 -0
- package/docs/wiki/Function.WebStorage.md +45 -0
- package/docs/wiki/Function.getExpired.md +21 -0
- package/docs/wiki/Function.stringify.md +17 -0
- package/docs/wiki/Home.md +33 -0
- package/docs/wiki/TypeAlias.ExpiredUnit.md +16 -0
- package/docs/wiki/Variable.isBrowser.md +11 -0
- package/docs/wiki/_Sidebar.md +30 -0
- package/docs/wiki/globals.md +30 -0
- package/package.json +5 -3
- package/docs/assets/icons.js +0 -15
- package/docs/assets/icons.svg +0 -1
- package/docs/assets/navigation.js +0 -1
- package/docs/assets/search.js +0 -1
- package/docs/assets/style.css +0 -1412
- package/docs/classes/EphemeralStorageService.html +0 -13
- package/docs/classes/LocalStorageService.html +0 -13
- package/docs/classes/MockStorage.html +0 -9
- package/docs/classes/SessionStorageService.html +0 -13
- package/docs/classes/StorageService.html +0 -14
- package/docs/functions/LocalStorage.html +0 -5
- package/docs/functions/SessionStorage.html +0 -5
- package/docs/functions/StorageGet.html +0 -1
- package/docs/functions/StorageHas.html +0 -1
- package/docs/functions/StorageKey.html +0 -1
- package/docs/functions/StorageRemove.html +0 -1
- package/docs/functions/StorageSet.html +0 -1
- package/docs/functions/WebStorage.html +0 -1
- package/docs/functions/getExpired.html +0 -1
- package/docs/functions/stringify.html +0 -1
- package/docs/hierarchy.html +0 -1
- package/docs/index.html +0 -25
- package/docs/modules.html +0 -18
- package/docs/types/ExpiredUnit.html +0 -9
- package/docs/variables/isBrowser.html +0 -4
- /package/docs/{.nojekyll → html/.nojekyll} +0 -0
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / StorageService
|
|
6
|
+
|
|
7
|
+
# Class: `abstract` StorageService
|
|
8
|
+
|
|
9
|
+
Defined in: [storage.service.ts:12](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L12)
|
|
10
|
+
|
|
11
|
+
## Extended by
|
|
12
|
+
|
|
13
|
+
- [`EphemeralStorageService`](EphemeralStorageService.md)
|
|
14
|
+
- [`LocalStorageService`](LocalStorageService.md)
|
|
15
|
+
- [`SessionStorageService`](SessionStorageService.md)
|
|
16
|
+
|
|
17
|
+
## Constructors
|
|
18
|
+
|
|
19
|
+
### new StorageService()
|
|
20
|
+
|
|
21
|
+
> `protected` **new StorageService**(`storage`): [`StorageService`](StorageService.md)
|
|
22
|
+
|
|
23
|
+
Defined in: [storage.service.ts:13](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L13)
|
|
24
|
+
|
|
25
|
+
#### Parameters
|
|
26
|
+
|
|
27
|
+
##### storage
|
|
28
|
+
|
|
29
|
+
`null` | `Storage`
|
|
30
|
+
|
|
31
|
+
#### Returns
|
|
32
|
+
|
|
33
|
+
[`StorageService`](StorageService.md)
|
|
34
|
+
|
|
35
|
+
## Methods
|
|
36
|
+
|
|
37
|
+
### clear()
|
|
38
|
+
|
|
39
|
+
> **clear**(): `void`
|
|
40
|
+
|
|
41
|
+
Defined in: [storage.service.ts:50](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L50)
|
|
42
|
+
|
|
43
|
+
#### Returns
|
|
44
|
+
|
|
45
|
+
`void`
|
|
46
|
+
|
|
47
|
+
***
|
|
48
|
+
|
|
49
|
+
### get()
|
|
50
|
+
|
|
51
|
+
> **get**(`key`): `any`
|
|
52
|
+
|
|
53
|
+
Defined in: [storage.service.ts:19](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L19)
|
|
54
|
+
|
|
55
|
+
#### Parameters
|
|
56
|
+
|
|
57
|
+
##### key
|
|
58
|
+
|
|
59
|
+
`string`
|
|
60
|
+
|
|
61
|
+
#### Returns
|
|
62
|
+
|
|
63
|
+
`any`
|
|
64
|
+
|
|
65
|
+
***
|
|
66
|
+
|
|
67
|
+
### has()
|
|
68
|
+
|
|
69
|
+
> **has**(`key`): `boolean`
|
|
70
|
+
|
|
71
|
+
Defined in: [storage.service.ts:15](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L15)
|
|
72
|
+
|
|
73
|
+
#### Parameters
|
|
74
|
+
|
|
75
|
+
##### key
|
|
76
|
+
|
|
77
|
+
`string`
|
|
78
|
+
|
|
79
|
+
#### Returns
|
|
80
|
+
|
|
81
|
+
`boolean`
|
|
82
|
+
|
|
83
|
+
***
|
|
84
|
+
|
|
85
|
+
### remove()
|
|
86
|
+
|
|
87
|
+
> **remove**(`key`): `void`
|
|
88
|
+
|
|
89
|
+
Defined in: [storage.service.ts:33](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L33)
|
|
90
|
+
|
|
91
|
+
Removes the specified key, e.g.:
|
|
92
|
+
- `remove('key')` Remove `key` key
|
|
93
|
+
- `remove(/BMap_\w+/)` Bulk delete all keys starting with BMap_
|
|
94
|
+
|
|
95
|
+
#### Parameters
|
|
96
|
+
|
|
97
|
+
##### key
|
|
98
|
+
|
|
99
|
+
key name or regular expression
|
|
100
|
+
|
|
101
|
+
`string` | `RegExp`
|
|
102
|
+
|
|
103
|
+
#### Returns
|
|
104
|
+
|
|
105
|
+
`void`
|
|
106
|
+
|
|
107
|
+
***
|
|
108
|
+
|
|
109
|
+
### set()
|
|
110
|
+
|
|
111
|
+
> **set**(`key`, `value`, `expiredAt`, `expiredUnit`): `void`
|
|
112
|
+
|
|
113
|
+
Defined in: [storage.service.ts:23](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L23)
|
|
114
|
+
|
|
115
|
+
#### Parameters
|
|
116
|
+
|
|
117
|
+
##### key
|
|
118
|
+
|
|
119
|
+
`string`
|
|
120
|
+
|
|
121
|
+
##### value
|
|
122
|
+
|
|
123
|
+
`any`
|
|
124
|
+
|
|
125
|
+
##### expiredAt
|
|
126
|
+
|
|
127
|
+
`number` = `0`
|
|
128
|
+
|
|
129
|
+
##### expiredUnit
|
|
130
|
+
|
|
131
|
+
[`ExpiredUnit`](../type-aliases/ExpiredUnit.md) = `'d'`
|
|
132
|
+
|
|
133
|
+
#### Returns
|
|
134
|
+
|
|
135
|
+
`void`
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / LocalStorage
|
|
6
|
+
|
|
7
|
+
# Function: LocalStorage()
|
|
8
|
+
|
|
9
|
+
> **LocalStorage**(`key`?, `expiredAt`?, `expiredUnit`?): (`target`, `propertyName`) => `void`
|
|
10
|
+
|
|
11
|
+
Defined in: [decorators/local-storage.ts:14](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/decorators/local-storage.ts#L14)
|
|
12
|
+
|
|
13
|
+
`localStorage` Decorator
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
### key?
|
|
18
|
+
|
|
19
|
+
`string`
|
|
20
|
+
|
|
21
|
+
Storage key
|
|
22
|
+
|
|
23
|
+
### expiredAt?
|
|
24
|
+
|
|
25
|
+
`number` = `0`
|
|
26
|
+
|
|
27
|
+
Expiration time, 0 means forever
|
|
28
|
+
|
|
29
|
+
### expiredUnit?
|
|
30
|
+
|
|
31
|
+
[`ExpiredUnit`](../type-aliases/ExpiredUnit.md) = `'t'`
|
|
32
|
+
|
|
33
|
+
Expiration time unit (default: custom [unit: ms])
|
|
34
|
+
|
|
35
|
+
## Returns
|
|
36
|
+
|
|
37
|
+
`Function`
|
|
38
|
+
|
|
39
|
+
### Parameters
|
|
40
|
+
|
|
41
|
+
#### target
|
|
42
|
+
|
|
43
|
+
`any`
|
|
44
|
+
|
|
45
|
+
#### propertyName
|
|
46
|
+
|
|
47
|
+
`string`
|
|
48
|
+
|
|
49
|
+
### Returns
|
|
50
|
+
|
|
51
|
+
`void`
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / SessionStorage
|
|
6
|
+
|
|
7
|
+
# Function: SessionStorage()
|
|
8
|
+
|
|
9
|
+
> **SessionStorage**(`key`?, `expiredAt`?, `expiredUnit`?): (`target`, `propertyName`) => `void`
|
|
10
|
+
|
|
11
|
+
Defined in: [decorators/session-storage.ts:14](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/decorators/session-storage.ts#L14)
|
|
12
|
+
|
|
13
|
+
`sessionStorage` Decorator
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
### key?
|
|
18
|
+
|
|
19
|
+
`string`
|
|
20
|
+
|
|
21
|
+
Storage key
|
|
22
|
+
|
|
23
|
+
### expiredAt?
|
|
24
|
+
|
|
25
|
+
`number` = `0`
|
|
26
|
+
|
|
27
|
+
Expiration time, 0 means forever
|
|
28
|
+
|
|
29
|
+
### expiredUnit?
|
|
30
|
+
|
|
31
|
+
[`ExpiredUnit`](../type-aliases/ExpiredUnit.md) = `'t'`
|
|
32
|
+
|
|
33
|
+
Expiration time unit (default: custom [unit: ms])
|
|
34
|
+
|
|
35
|
+
## Returns
|
|
36
|
+
|
|
37
|
+
`Function`
|
|
38
|
+
|
|
39
|
+
### Parameters
|
|
40
|
+
|
|
41
|
+
#### target
|
|
42
|
+
|
|
43
|
+
`any`
|
|
44
|
+
|
|
45
|
+
#### propertyName
|
|
46
|
+
|
|
47
|
+
`string`
|
|
48
|
+
|
|
49
|
+
### Returns
|
|
50
|
+
|
|
51
|
+
`void`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / StorageGet
|
|
6
|
+
|
|
7
|
+
# Function: StorageGet()
|
|
8
|
+
|
|
9
|
+
> **StorageGet**(`storage`, `key`): `unknown`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:20](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L20)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### storage
|
|
16
|
+
|
|
17
|
+
`null` | `Storage`
|
|
18
|
+
|
|
19
|
+
### key
|
|
20
|
+
|
|
21
|
+
`string`
|
|
22
|
+
|
|
23
|
+
## Returns
|
|
24
|
+
|
|
25
|
+
`unknown`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / StorageHas
|
|
6
|
+
|
|
7
|
+
# Function: StorageHas()
|
|
8
|
+
|
|
9
|
+
> **StorageHas**(`storage`, `key`): `boolean`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:37](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L37)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### storage
|
|
16
|
+
|
|
17
|
+
`null` | `Storage`
|
|
18
|
+
|
|
19
|
+
### key
|
|
20
|
+
|
|
21
|
+
`string`
|
|
22
|
+
|
|
23
|
+
## Returns
|
|
24
|
+
|
|
25
|
+
`boolean`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / StorageKey
|
|
6
|
+
|
|
7
|
+
# Function: StorageKey()
|
|
8
|
+
|
|
9
|
+
> **StorageKey**(`storage`, `index`): `null` \| `string`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:65](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L65)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### storage
|
|
16
|
+
|
|
17
|
+
`null` | `Storage`
|
|
18
|
+
|
|
19
|
+
### index
|
|
20
|
+
|
|
21
|
+
`number`
|
|
22
|
+
|
|
23
|
+
## Returns
|
|
24
|
+
|
|
25
|
+
`null` \| `string`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / StorageRemove
|
|
6
|
+
|
|
7
|
+
# Function: StorageRemove()
|
|
8
|
+
|
|
9
|
+
> **StorageRemove**(`storage`, `key`): `void`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:58](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L58)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### storage
|
|
16
|
+
|
|
17
|
+
`null` | `Storage`
|
|
18
|
+
|
|
19
|
+
### key
|
|
20
|
+
|
|
21
|
+
`string`
|
|
22
|
+
|
|
23
|
+
## Returns
|
|
24
|
+
|
|
25
|
+
`void`
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / StorageSet
|
|
6
|
+
|
|
7
|
+
# Function: StorageSet()
|
|
8
|
+
|
|
9
|
+
> **StorageSet**(`storage`, `key`, `value`, `expiredAt`, `expiredUnit`): `void`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:44](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L44)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### storage
|
|
16
|
+
|
|
17
|
+
`null` | `Storage`
|
|
18
|
+
|
|
19
|
+
### key
|
|
20
|
+
|
|
21
|
+
`string`
|
|
22
|
+
|
|
23
|
+
### value
|
|
24
|
+
|
|
25
|
+
`any`
|
|
26
|
+
|
|
27
|
+
### expiredAt
|
|
28
|
+
|
|
29
|
+
`number` = `0`
|
|
30
|
+
|
|
31
|
+
### expiredUnit
|
|
32
|
+
|
|
33
|
+
[`ExpiredUnit`](../type-aliases/ExpiredUnit.md) = `'t'`
|
|
34
|
+
|
|
35
|
+
## Returns
|
|
36
|
+
|
|
37
|
+
`void`
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / WebStorage
|
|
6
|
+
|
|
7
|
+
# Function: WebStorage()
|
|
8
|
+
|
|
9
|
+
> **WebStorage**(`storage`, `key`?, `expiredAt`?, `expiredUnit`?): (`target`, `propertyName`) => `void`
|
|
10
|
+
|
|
11
|
+
Defined in: [decorators/web-storage.ts:16](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/decorators/web-storage.ts#L16)
|
|
12
|
+
|
|
13
|
+
**`Internal`**
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
### storage
|
|
18
|
+
|
|
19
|
+
`null` | `Storage`
|
|
20
|
+
|
|
21
|
+
### key?
|
|
22
|
+
|
|
23
|
+
`string`
|
|
24
|
+
|
|
25
|
+
### expiredAt?
|
|
26
|
+
|
|
27
|
+
`number` = `0`
|
|
28
|
+
|
|
29
|
+
### expiredUnit?
|
|
30
|
+
|
|
31
|
+
[`ExpiredUnit`](../type-aliases/ExpiredUnit.md) = `'d'`
|
|
32
|
+
|
|
33
|
+
## Returns
|
|
34
|
+
|
|
35
|
+
`Function`
|
|
36
|
+
|
|
37
|
+
### Parameters
|
|
38
|
+
|
|
39
|
+
#### target
|
|
40
|
+
|
|
41
|
+
`any`
|
|
42
|
+
|
|
43
|
+
#### propertyName
|
|
44
|
+
|
|
45
|
+
`string`
|
|
46
|
+
|
|
47
|
+
### Returns
|
|
48
|
+
|
|
49
|
+
`void`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / getExpired
|
|
6
|
+
|
|
7
|
+
# Function: getExpired()
|
|
8
|
+
|
|
9
|
+
> **getExpired**(`val`, `unit`): `number`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:72](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L72)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### val
|
|
16
|
+
|
|
17
|
+
`number`
|
|
18
|
+
|
|
19
|
+
### unit
|
|
20
|
+
|
|
21
|
+
[`ExpiredUnit`](../type-aliases/ExpiredUnit.md)
|
|
22
|
+
|
|
23
|
+
## Returns
|
|
24
|
+
|
|
25
|
+
`number`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / stringify
|
|
6
|
+
|
|
7
|
+
# Function: stringify()
|
|
8
|
+
|
|
9
|
+
> **stringify**(`value`): `string`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:98](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L98)
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
### value
|
|
16
|
+
|
|
17
|
+
`any`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`string`
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
# @rxap/ngx-memory
|
|
6
|
+
|
|
7
|
+
## Classes
|
|
8
|
+
|
|
9
|
+
- [EphemeralStorageService](classes/EphemeralStorageService.md)
|
|
10
|
+
- [LocalStorageService](classes/LocalStorageService.md)
|
|
11
|
+
- [MockStorage](classes/MockStorage.md)
|
|
12
|
+
- [SessionStorageService](classes/SessionStorageService.md)
|
|
13
|
+
- [StorageService](classes/StorageService.md)
|
|
14
|
+
|
|
15
|
+
## Type Aliases
|
|
16
|
+
|
|
17
|
+
- [ExpiredUnit](type-aliases/ExpiredUnit.md)
|
|
18
|
+
|
|
19
|
+
## Variables
|
|
20
|
+
|
|
21
|
+
- [isBrowser](variables/isBrowser.md)
|
|
22
|
+
|
|
23
|
+
## Functions
|
|
24
|
+
|
|
25
|
+
- [getExpired](functions/getExpired.md)
|
|
26
|
+
- [LocalStorage](functions/LocalStorage.md)
|
|
27
|
+
- [SessionStorage](functions/SessionStorage.md)
|
|
28
|
+
- [StorageGet](functions/StorageGet.md)
|
|
29
|
+
- [StorageHas](functions/StorageHas.md)
|
|
30
|
+
- [StorageKey](functions/StorageKey.md)
|
|
31
|
+
- [StorageRemove](functions/StorageRemove.md)
|
|
32
|
+
- [StorageSet](functions/StorageSet.md)
|
|
33
|
+
- [stringify](functions/stringify.md)
|
|
34
|
+
- [WebStorage](functions/WebStorage.md)
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / ExpiredUnit
|
|
6
|
+
|
|
7
|
+
# Type Alias: ExpiredUnit
|
|
8
|
+
|
|
9
|
+
> **ExpiredUnit**: `"s"` \| `"m"` \| `"h"` \| `"d"` \| `"w"` \| `"y"` \| `"t"`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:11](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L11)
|
|
12
|
+
|
|
13
|
+
Expiration time unit
|
|
14
|
+
s: seconds
|
|
15
|
+
m: minute
|
|
16
|
+
h: hour
|
|
17
|
+
d: day
|
|
18
|
+
w: week
|
|
19
|
+
y: year
|
|
20
|
+
t: Custom (millisecond)
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
[**@rxap/ngx-memory**](../README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
[@rxap/ngx-memory](../globals.md) / isBrowser
|
|
6
|
+
|
|
7
|
+
# Variable: isBrowser
|
|
8
|
+
|
|
9
|
+
> `const` **isBrowser**: `boolean`
|
|
10
|
+
|
|
11
|
+
Defined in: [storage-utility.ts:18](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage-utility.ts#L18)
|
|
12
|
+
|
|
13
|
+
Determining if an Angular application is rendered in the browser
|
|
14
|
+
The Angular `PLATFORM_ID` identifier cannot be used directly by the `decorator`.
|
|
15
|
+
The advantage of this is that it also works well when the server populates the Document itself.
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
[@rxap/ngx-memory](../wiki/globals) / EphemeralStorageService
|
|
2
|
+
|
|
3
|
+
# Class: EphemeralStorageService
|
|
4
|
+
|
|
5
|
+
Defined in: [ephemeral-storage.service.ts:6](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/ephemeral-storage.service.ts#L6)
|
|
6
|
+
|
|
7
|
+
## Extends
|
|
8
|
+
|
|
9
|
+
- [`StorageService`](../wiki/Class.StorageService)
|
|
10
|
+
|
|
11
|
+
## Constructors
|
|
12
|
+
|
|
13
|
+
### new EphemeralStorageService()
|
|
14
|
+
|
|
15
|
+
> **new EphemeralStorageService**(): [`EphemeralStorageService`](../wiki/Class.EphemeralStorageService)
|
|
16
|
+
|
|
17
|
+
Defined in: [ephemeral-storage.service.ts:8](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/ephemeral-storage.service.ts#L8)
|
|
18
|
+
|
|
19
|
+
#### Returns
|
|
20
|
+
|
|
21
|
+
[`EphemeralStorageService`](../wiki/Class.EphemeralStorageService)
|
|
22
|
+
|
|
23
|
+
#### Overrides
|
|
24
|
+
|
|
25
|
+
[`StorageService`](../wiki/Class.StorageService).[`constructor`](../wiki/Class.StorageService#constructors)
|
|
26
|
+
|
|
27
|
+
## Methods
|
|
28
|
+
|
|
29
|
+
### clear()
|
|
30
|
+
|
|
31
|
+
> **clear**(): `void`
|
|
32
|
+
|
|
33
|
+
Defined in: [storage.service.ts:50](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L50)
|
|
34
|
+
|
|
35
|
+
#### Returns
|
|
36
|
+
|
|
37
|
+
`void`
|
|
38
|
+
|
|
39
|
+
#### Inherited from
|
|
40
|
+
|
|
41
|
+
[`StorageService`](../wiki/Class.StorageService).[`clear`](../wiki/Class.StorageService#clear)
|
|
42
|
+
|
|
43
|
+
***
|
|
44
|
+
|
|
45
|
+
### get()
|
|
46
|
+
|
|
47
|
+
> **get**(`key`): `any`
|
|
48
|
+
|
|
49
|
+
Defined in: [storage.service.ts:19](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L19)
|
|
50
|
+
|
|
51
|
+
#### Parameters
|
|
52
|
+
|
|
53
|
+
##### key
|
|
54
|
+
|
|
55
|
+
`string`
|
|
56
|
+
|
|
57
|
+
#### Returns
|
|
58
|
+
|
|
59
|
+
`any`
|
|
60
|
+
|
|
61
|
+
#### Inherited from
|
|
62
|
+
|
|
63
|
+
[`StorageService`](../wiki/Class.StorageService).[`get`](../wiki/Class.StorageService#get)
|
|
64
|
+
|
|
65
|
+
***
|
|
66
|
+
|
|
67
|
+
### has()
|
|
68
|
+
|
|
69
|
+
> **has**(`key`): `boolean`
|
|
70
|
+
|
|
71
|
+
Defined in: [storage.service.ts:15](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L15)
|
|
72
|
+
|
|
73
|
+
#### Parameters
|
|
74
|
+
|
|
75
|
+
##### key
|
|
76
|
+
|
|
77
|
+
`string`
|
|
78
|
+
|
|
79
|
+
#### Returns
|
|
80
|
+
|
|
81
|
+
`boolean`
|
|
82
|
+
|
|
83
|
+
#### Inherited from
|
|
84
|
+
|
|
85
|
+
[`StorageService`](../wiki/Class.StorageService).[`has`](../wiki/Class.StorageService#has)
|
|
86
|
+
|
|
87
|
+
***
|
|
88
|
+
|
|
89
|
+
### remove()
|
|
90
|
+
|
|
91
|
+
> **remove**(`key`): `void`
|
|
92
|
+
|
|
93
|
+
Defined in: [storage.service.ts:33](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L33)
|
|
94
|
+
|
|
95
|
+
Removes the specified key, e.g.:
|
|
96
|
+
- `remove('key')` Remove `key` key
|
|
97
|
+
- `remove(/BMap_\w+/)` Bulk delete all keys starting with BMap_
|
|
98
|
+
|
|
99
|
+
#### Parameters
|
|
100
|
+
|
|
101
|
+
##### key
|
|
102
|
+
|
|
103
|
+
key name or regular expression
|
|
104
|
+
|
|
105
|
+
`string` | `RegExp`
|
|
106
|
+
|
|
107
|
+
#### Returns
|
|
108
|
+
|
|
109
|
+
`void`
|
|
110
|
+
|
|
111
|
+
#### Inherited from
|
|
112
|
+
|
|
113
|
+
[`StorageService`](../wiki/Class.StorageService).[`remove`](../wiki/Class.StorageService#remove)
|
|
114
|
+
|
|
115
|
+
***
|
|
116
|
+
|
|
117
|
+
### set()
|
|
118
|
+
|
|
119
|
+
> **set**(`key`, `value`, `expiredAt`, `expiredUnit`): `void`
|
|
120
|
+
|
|
121
|
+
Defined in: [storage.service.ts:23](https://gitlab.com/rxap/packages/-/blob/969f0867a1da05a157f626d5bdd316bd0a67494a/packages/angular/memory/src/lib/storage.service.ts#L23)
|
|
122
|
+
|
|
123
|
+
#### Parameters
|
|
124
|
+
|
|
125
|
+
##### key
|
|
126
|
+
|
|
127
|
+
`string`
|
|
128
|
+
|
|
129
|
+
##### value
|
|
130
|
+
|
|
131
|
+
`any`
|
|
132
|
+
|
|
133
|
+
##### expiredAt
|
|
134
|
+
|
|
135
|
+
`number` = `0`
|
|
136
|
+
|
|
137
|
+
##### expiredUnit
|
|
138
|
+
|
|
139
|
+
[`ExpiredUnit`](../wiki/TypeAlias.ExpiredUnit) = `'d'`
|
|
140
|
+
|
|
141
|
+
#### Returns
|
|
142
|
+
|
|
143
|
+
`void`
|
|
144
|
+
|
|
145
|
+
#### Inherited from
|
|
146
|
+
|
|
147
|
+
[`StorageService`](../wiki/Class.StorageService).[`set`](../wiki/Class.StorageService#set)
|