KeyValueProvider
@daydreamsai/core / KeyValueProvider
Interface: KeyValueProvider
Defined in: packages/core/src/memory/types.ts:91
Key-Value storage provider
Extends
Methods
close()
close():
Promise<void>
Defined in: packages/core/src/memory/types.ts:78
Returns
Promise<void>
Inherited from
count()
count(
pattern?):Promise<number>
Defined in: packages/core/src/memory/types.ts:97
Parameters
pattern?
string
Returns
Promise<number>
delete()
delete(
key):Promise<boolean>
Defined in: packages/core/src/memory/types.ts:94
Parameters
key
string
Returns
Promise<boolean>
deleteBatch()
deleteBatch(
keys):Promise<number>
Defined in: packages/core/src/memory/types.ts:103
Parameters
keys
string[]
Returns
Promise<number>
exists()
exists(
key):Promise<boolean>
Defined in: packages/core/src/memory/types.ts:95
Parameters
key
string
Returns
Promise<boolean>
get()
get<
T>(key):Promise<null|T>
Defined in: packages/core/src/memory/types.ts:92
Type Parameters
T
T
Parameters
key
string
Returns
Promise<null | T>
getBatch()
getBatch<
T>(keys):Promise<Map<string,T>>
Defined in: packages/core/src/memory/types.ts:101
Type Parameters
T
T
Parameters
keys
string[]
Returns
Promise<Map<string, T>>
health()
health():
Promise<HealthStatus>
Defined in: packages/core/src/memory/types.ts:79
Returns
Promise<HealthStatus>
Inherited from
initialize()
initialize():
Promise<void>
Defined in: packages/core/src/memory/types.ts:77
Returns
Promise<void>
Inherited from
keys()
keys(
pattern?):Promise<string[]>
Defined in: packages/core/src/memory/types.ts:96
Parameters
pattern?
string
Returns
Promise<string[]>
scan()
scan(
pattern?):AsyncIterator<[string,unknown]>
Defined in: packages/core/src/memory/types.ts:98
Parameters
pattern?
string
Returns
AsyncIterator<[string, unknown]>
set()
set<
T>(key,value,options?):Promise<void>
Defined in: packages/core/src/memory/types.ts:93
Type Parameters
T
T
Parameters
key
string
value
T
options?
Returns
Promise<void>
setBatch()
setBatch<
T>(entries,options?):Promise<void>
Defined in: packages/core/src/memory/types.ts:102
Type Parameters
T
T
Parameters
entries
Map<string, T>
options?
Returns
Promise<void>