Class: Config
moralis-monorepo / @moralisweb3/common-core / Config
Class: Config
@moralisweb3/common-core.Config
Table of contents
Constructors
Methods
Constructors
constructor
• new Config()
Methods
get
▸ get<Value
>(keyOrName
): Value
Type parameters
Name |
---|
Value |
Parameters
Name | Type |
---|---|
keyOrName | string | ConfigKey <Value > |
Returns
Value
getKeys
▸ getKeys(): string
[]
Returns
string
[]
hasKey
▸ hasKey<Value
>(key
): boolean
Type parameters
Name |
---|
Value |
Parameters
Name | Type |
---|---|
key | ConfigKey <Value > |
Returns
boolean
merge
▸ merge(values
): void
Parameters
Name | Type |
---|---|
values | ConfigValues |
Returns
void
registerKey
▸ registerKey<Value
>(key
, validator?
): void
Type parameters
Name |
---|
Value |
Parameters
Name | Type |
---|---|
key | ConfigKey <Value > |
validator? | ConfigKeyValidator <Value > |
Returns
void
reset
▸ reset(): void
Returns
void
set
▸ set<Value
>(keyOrName
, value
): void
Type parameters
Name |
---|
Value |
Parameters
Name | Type |
---|---|
keyOrName | string | ConfigKey <Value > |
value | Value |
Returns
void