Class: SimpleKVStore
Hierarchy
-
↳
SimpleKVStore
Constructors
constructor
• new SimpleKVStore(data?
): SimpleKVStore
Parameters
Name | Type |
---|---|
data | DataType |
Returns
Overrides
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:14
Properties
data
• Private
data: DataType
= {}
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:14
fs
• Private
fs: undefined
| GenericFileSystem
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:12
persistPath
• Private
persistPath: undefined
| string
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:11
Methods
delete
▸ delete(key
, collection?
): Promise
<boolean
>
Parameters
Name | Type | Default value |
---|---|---|
key | string | undefined |
collection | string | DEFAULT_COLLECTION |
Returns
Promise
<boolean
>
Overrides
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:51
get
▸ get(key
, collection?
): Promise
<any
>
Parameters
Name | Type | Default value |
---|---|---|
key | string | undefined |
collection | string | DEFAULT_COLLECTION |
Returns
Promise
<any
>
Overrides
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:33
getAll
▸ getAll(collection?
): Promise
<DataType
>
Parameters
Name | Type | Default value |
---|---|---|
collection | string | DEFAULT_COLLECTION |
Returns
Promise
<DataType
>
Overrides
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:47
persist
▸ persist(persistPath
, fs?
): Promise
<void
>
Parameters
Name | Type | Default value |
---|---|---|
persistPath | string | undefined |
fs | GenericFileSystem | defaultFS |
Returns
Promise
<void
>
Defined in
packages/core/src/storage/kvStore/SimpleKVStore.ts:65