(key: T, value: SystemConfigValueType<T>)
| 179 | } |
| 180 | |
| 181 | public set<T extends SystemConfigKey>(key: T, value: SystemConfigValueType<T>): void { |
| 182 | const funcName = `set${toCamelCase(key)}`; |
| 183 | // @ts-ignore |
| 184 | if (typeof this[funcName] === "function") { |
| 185 | // @ts-ignore |
| 186 | this[funcName](value); |
| 187 | } else { |
| 188 | throw new Error(`Method ${funcName} does not exist on SystemConfig`); |
| 189 | } |
| 190 | } |
| 191 | |
| 192 | private _set<T extends SystemConfigKey>(key: T, value: SystemConfigValueType<T> | undefined) { |
| 193 | const prev = this.cache.get(key); |
nothing calls this directly
no test coverage detected