build(deps-dev): apply updates
[e-mobility-charging-stations-simulator.git] / src / charging-station / ui-server / ui-services / UIServiceFactory.ts
CommitLineData
4c3c0d59
JB
1import type { AbstractUIService } from './AbstractUIService';
2import { UIService001 } from './UIService001';
268a74bb 3import { ProtocolVersion } from '../../../types';
4c3c0d59 4import type { AbstractUIServer } from '../AbstractUIServer';
4198ad5c 5
268a74bb 6export class UIServiceFactory {
4198ad5c
JB
7 private constructor() {
8 // This is intentional
9 }
10
e7aeea18
JB
11 public static getUIServiceImplementation(
12 version: ProtocolVersion,
5edd8ba0 13 uiServer: AbstractUIServer,
551e477c 14 ): AbstractUIService {
4198ad5c
JB
15 switch (version) {
16 case ProtocolVersion['0.0.1']:
675fa8e3 17 return new UIService001(uiServer);
4198ad5c
JB
18 }
19 }
20}