From 2a3cf7fc8bbfc899369079cd133c1c659ff0a653 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Fri, 9 Sep 2022 07:15:09 +0200 Subject: [PATCH] UI Server: refine methods scope MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- .../ui-services/AbstractUIService.ts | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/charging-station/ui-server/ui-services/AbstractUIService.ts b/src/charging-station/ui-server/ui-services/AbstractUIService.ts index 2cfd85fa..0db59cca 100644 --- a/src/charging-station/ui-server/ui-services/AbstractUIService.ts +++ b/src/charging-station/ui-server/ui-services/AbstractUIService.ts @@ -127,7 +127,21 @@ export default abstract class AbstractUIService { return this.broadcastChannelRequests.get(uuid) ?? 0; } - protected sendBroadcastChannelRequest( + protected handleProtocolRequest( + uuid: string, + procedureName: ProcedureName, + payload: RequestPayload + ): void { + this.sendBroadcastChannelRequest( + uuid, + AbstractUIService.ProcedureNameToBroadCastChannelProcedureNameMap[ + procedureName + ] as BroadcastChannelProcedureName, + payload + ); + } + + private sendBroadcastChannelRequest( uuid: string, procedureName: BroadcastChannelProcedureName, payload: BroadcastChannelRequestPayload @@ -154,20 +168,6 @@ export default abstract class AbstractUIService { this.broadcastChannelRequests.set(uuid, expectedNumberOfResponses); } - protected handleProtocolRequest( - uuid: string, - procedureName: ProcedureName, - payload: RequestPayload - ): void { - this.sendBroadcastChannelRequest( - uuid, - AbstractUIService.ProcedureNameToBroadCastChannelProcedureNameMap[ - procedureName - ] as BroadcastChannelProcedureName, - payload - ); - } - private handleListChargingStations(): ResponsePayload { return { status: ResponseStatus.SUCCESS, -- 2.34.1