@terascope/teraslice-state-storage / cached-state-storage / default
Class: default<T>
Extends
EventEmitter
Type parameters
Type parameter |
---|
T |
Constructors
new default()
new default<
T
>(config
):default
<T
>
Parameters
Parameter | Type |
---|---|
config | CacheConfig |
Returns
default
<T
>
Overrides
EventEmitter.constructor
Source
cached-state-storage/index.ts:11
Methods
clear()
clear():
void
Returns
void
Source
cached-state-storage/index.ts:60
count()
count():
number
Returns
number
Source
cached-state-storage/index.ts:41
get()
get(
key
):undefined
|T
Parameters
Parameter | Type |
---|---|
key | string | number |
Returns
undefined
| T
Source
cached-state-storage/index.ts:16
has()
has(
key
):boolean
Parameters
Parameter | Type |
---|---|
key | string | number |
Returns
boolean
Source
cached-state-storage/index.ts:56
mget()
mget(
keyArray
):MGetCacheResponse
Parameters
Parameter | Type |
---|---|
keyArray | (string | number )[] |
Returns
Source
cached-state-storage/index.ts:20
mset()
mset(
docArray
):void
Parameters
Parameter | Type |
---|---|
docArray | SetTuple <T >[] |
Returns
void
Source
cached-state-storage/index.ts:35
set()
set(
key
,value
):void
Parameters
Parameter | Type |
---|---|
key | string | number |
value | T |
Returns
void
Source
cached-state-storage/index.ts:28
values()
values(
fn
):Promise
<void
>
Parameters
Parameter | Type |
---|---|
fn | ValuesFn <T > |
Returns
Promise
<void
>