From: Jérôme Benoit Date: Sun, 16 Jul 2023 22:11:12 +0000 (+0200) Subject: refactor: order configuration class methods X-Git-Tag: v1.2.18~17 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=c831d2bcf192839310f736ab508a0050eec451ea;p=e-mobility-charging-stations-simulator.git refactor: order configuration class methods Signed-off-by: Jérôme Benoit --- diff --git a/src/utils/Configuration.ts b/src/utils/Configuration.ts index d9c297e9..ae3d8e9f 100644 --- a/src/utils/Configuration.ts +++ b/src/utils/Configuration.ts @@ -104,16 +104,6 @@ export class Configuration { return Configuration.getConfigurationData()?.stationTemplateUrls; } - public static workerPoolInUse(): boolean { - return [WorkerProcessType.dynamicPool, WorkerProcessType.staticPool].includes( - Configuration.buildWorkerSection().processType!, - ); - } - - public static workerDynamicPoolInUse(): boolean { - return Configuration.buildWorkerSection().processType === WorkerProcessType.dynamicPool; - } - public static getSupervisionUrls(): string | string[] | undefined { Configuration.warnDeprecatedConfigurationKey( 'supervisionURLs', @@ -146,6 +136,16 @@ export class Configuration { : SupervisionUrlDistribution.ROUND_ROBIN; } + public static workerPoolInUse(): boolean { + return [WorkerProcessType.dynamicPool, WorkerProcessType.staticPool].includes( + Configuration.buildWorkerSection().processType!, + ); + } + + public static workerDynamicPoolInUse(): boolean { + return Configuration.buildWorkerSection().processType === WorkerProcessType.dynamicPool; + } + private static buildUIServerSection(): UIServerConfiguration { if (hasOwnProp(Configuration.getConfigurationData(), 'uiWebSocketServer')) { console.error(