version: 4.0.2(release-it@15.10.1)
'@rollup/plugin-json':
specifier: ^6.0.0
- version: 6.0.0(rollup@3.20.4)
+ version: 6.0.0(rollup@3.20.6)
'@rollup/plugin-terser':
specifier: ^0.4.1
- version: 0.4.1(rollup@3.20.4)
+ version: 0.4.1(rollup@3.20.6)
'@rollup/plugin-typescript':
specifier: ^11.1.0
- version: 11.1.0(rollup@3.20.4)(tslib@2.5.0)(typescript@5.0.4)
+ version: 11.1.0(rollup@3.20.6)(tslib@2.5.0)(typescript@5.0.4)
'@types/mocha':
specifier: ^10.0.1
version: 10.0.1
specifier: ^2.27.5
version: 2.27.5(@typescript-eslint/parser@5.59.0)(eslint-import-resolver-typescript@3.5.5)(eslint@8.38.0)
eslint-plugin-jsdoc:
- specifier: ^41.1.2
- version: 41.1.2(eslint@8.38.0)
+ specifier: ^43.0.3
+ version: 43.0.3(eslint@8.38.0)
eslint-plugin-n:
specifier: ^15.7.0
version: 15.7.0(eslint@8.38.0)
specifier: ^0.6.9
version: 0.6.9(bufferutil@4.0.7)(utf-8-validate@6.0.3)
rollup:
- specifier: ^3.20.4
- version: 3.20.4
+ specifier: ^3.20.6
+ version: 3.20.6
rollup-plugin-analyzer:
specifier: ^4.0.0
version: 4.0.0
'@octokit/openapi-types': 16.0.0
dev: true
+ /@pkgjs/parseargs@0.11.0:
+ resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==}
+ engines: {node: '>=14'}
+ requiresBuild: true
+ dev: true
+ optional: true
+
/@pkgr/utils@2.3.1:
resolution: {integrity: sha512-wfzX8kc1PMyUILA+1Z/EqoE4UCXGy0iRGMhPwdfae1+f0OXlLqCk+By+aMzgJBzR9AzS4CDizioG6Ss1gvAFJw==}
engines: {node: ^12.20.0 || ^14.18.0 || >=16.0.0}
semver: 7.5.0
dev: true
- /@rollup/plugin-json@6.0.0(rollup@3.20.4):
+ /@rollup/plugin-json@6.0.0(rollup@3.20.6):
resolution: {integrity: sha512-i/4C5Jrdr1XUarRhVu27EEwjt4GObltD7c+MkCIpO2QIbojw8MUs+CCTqOphQi3Qtg1FLmYt+l+6YeoIf51J7w==}
engines: {node: '>=14.0.0'}
peerDependencies:
rollup:
optional: true
dependencies:
- '@rollup/pluginutils': 5.0.2(rollup@3.20.4)
- rollup: 3.20.4
+ '@rollup/pluginutils': 5.0.2(rollup@3.20.6)
+ rollup: 3.20.6
dev: true
- /@rollup/plugin-terser@0.4.1(rollup@3.20.4):
+ /@rollup/plugin-terser@0.4.1(rollup@3.20.6):
resolution: {integrity: sha512-aKS32sw5a7hy+fEXVy+5T95aDIwjpGHCTv833HXVtyKMDoVS7pBr5K3L9hEQoNqbJFjfANPrNpIXlTQ7is00eA==}
engines: {node: '>=14.0.0'}
peerDependencies:
rollup:
optional: true
dependencies:
- rollup: 3.20.4
+ rollup: 3.20.6
serialize-javascript: 6.0.1
smob: 0.0.6
- terser: 5.16.9
+ terser: 5.17.0
dev: true
- /@rollup/plugin-typescript@11.1.0(rollup@3.20.4)(tslib@2.5.0)(typescript@5.0.4):
+ /@rollup/plugin-typescript@11.1.0(rollup@3.20.6)(tslib@2.5.0)(typescript@5.0.4):
resolution: {integrity: sha512-86flrfE+bSHB69znnTV6kVjkncs2LBMhcTCyxWgRxLyfXfQrxg4UwlAqENnjrrxnSNS/XKCDJCl8EkdFJVHOxw==}
engines: {node: '>=14.0.0'}
peerDependencies:
tslib:
optional: true
dependencies:
- '@rollup/pluginutils': 5.0.2(rollup@3.20.4)
+ '@rollup/pluginutils': 5.0.2(rollup@3.20.6)
resolve: 1.22.2
- rollup: 3.20.4
+ rollup: 3.20.6
tslib: 2.5.0
typescript: 5.0.4
dev: true
- /@rollup/pluginutils@5.0.2(rollup@3.20.4):
+ /@rollup/pluginutils@5.0.2(rollup@3.20.6):
resolution: {integrity: sha512-pTd9rIsP92h+B6wWwFbW8RkZv4hiR/xKsqre4SIuAOaOEQRxi0lqLke9k2/7WegC85GgUs9pjmOjCUi3In4vwA==}
engines: {node: '>=14.0.0'}
peerDependencies:
'@types/estree': 1.0.0
estree-walker: 2.0.2
picomatch: 2.3.1
- rollup: 3.20.4
+ rollup: 3.20.6
dev: true
/@sinclair/typebox@0.25.24:
- supports-color
dev: true
- /eslint-plugin-jsdoc@41.1.2(eslint@8.38.0):
- resolution: {integrity: sha512-MePJXdGiPW7AG06CU5GbKzYtKpoHwTq1lKijjq+RwL/cQkZtBZ59Zbv5Ep0RVxSMnq6242249/n+w4XrTZ1Afg==}
+ /eslint-plugin-jsdoc@43.0.3(eslint@8.38.0):
+ resolution: {integrity: sha512-tHlpaUqB8ih2IhQw7Es/R3Z3anQZVfPUb33nUAVOgIcMugVYyD1ZE/KXjjN8HxykZsV1IXqrKZkKpUBrEi3G9Q==}
engines: {node: ^14 || ^16 || ^17 || ^18 || ^19}
peerDependencies:
eslint: ^7.0.0 || ^8.0.0
signal-exit: 3.0.7
dev: true
+ /foreground-child@3.1.1:
+ resolution: {integrity: sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg==}
+ engines: {node: '>=14'}
+ dependencies:
+ cross-spawn: 7.0.3
+ signal-exit: 4.0.1
+ dev: true
+
/forever-agent@0.6.1:
resolution: {integrity: sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==}
dev: true
is-glob: 4.0.3
dev: true
- /glob@10.1.0:
- resolution: {integrity: sha512-daGobsYuT0G4hng24B5LbeLNvwKZYRhWyDl3RvqqAGZjJnCopWWK6PWnAGBY1M/vdA63QE+jddhZcYp+74Bq6Q==}
+ /glob@10.2.1:
+ resolution: {integrity: sha512-ngom3wq2UhjdbmRE/krgkD8BQyi1KZ5l+D2dVm4+Yj+jJIBp74/ZGunL6gNGc/CYuQmvUBiavWEXIotRiv5R6A==}
engines: {node: '>=16 || 14 >=14.17'}
+ hasBin: true
dependencies:
+ foreground-child: 3.1.1
fs.realpath: 1.0.0
+ jackspeak: 2.0.3
minimatch: 9.0.0
minipass: 5.0.0
path-scurry: 1.7.0
iterate-iterator: 1.0.2
dev: true
+ /jackspeak@2.0.3:
+ resolution: {integrity: sha512-0Jud3OMUdMbrlr3PyUMKESq51LXVAB+a239Ywdvd+Kgxj3MaBRml/nVRxf8tQFyfthMjuRkxkv7Vg58pmIMfuQ==}
+ engines: {node: '>=14'}
+ dependencies:
+ cliui: 7.0.4
+ optionalDependencies:
+ '@pkgjs/parseargs': 0.11.0
+ dev: true
+
/jake@10.8.5:
resolution: {integrity: sha512-sVpxYeuAhWt0OTWITwT98oyV0GsXyMlXCF+3L1SuafBVUIr/uILGRB+NqwkzhgXKvoJpDIpQvqkUALgdmQsQxw==}
engines: {node: '>=10'}
dependencies:
yallist: 4.0.0
- /lru-cache@9.0.3:
- resolution: {integrity: sha512-cyjNRew29d4kbgnz1sjDqxg7qg8NW4s+HQzCGjeon7DV5T2yDije16W9HaUFV1dhVEMh+SjrOcK0TomBmf3Egg==}
+ /lru-cache@9.1.0:
+ resolution: {integrity: sha512-qFXQEwchrZcMVen2uIDceR8Tii6kCJak5rzDStfEM0qA3YLMswaxIEZO0DhIbJ3aqaJiDjt+3crlplOb0tDtKQ==}
engines: {node: 14 || >=16.14}
dev: true
resolution: {integrity: sha512-UkZUeDjczjYRE495+9thsgcVgsaCPkaw80slmfVFgllxY+IO8ubTsOpFVjDPROBqJdHfVPUFRHPBV/WciOVfWg==}
engines: {node: '>=16 || 14 >=14.17'}
dependencies:
- lru-cache: 9.0.3
+ lru-cache: 9.1.0
minipass: 5.0.0
dev: true
engines: {node: '>=14'}
hasBin: true
dependencies:
- glob: 10.1.0
+ glob: 10.2.1
dev: true
/ripemd160@2.0.2:
del: 5.1.0
dev: true
- /rollup@3.20.4:
- resolution: {integrity: sha512-n7J4tuctZXUErM9Uc916httwqmTc63zzCr2+TLCiSCpfO/Xuk3g/marGN1IlRJZi+QF3XMYx75PxXRfZDVgaRw==}
+ /rollup@3.20.6:
+ resolution: {integrity: sha512-2yEB3nQXp/tBQDN0hJScJQheXdvU2wFhh6ld7K/aiZ1vYcak6N/BKjY1QrU6BvO2JWYS8bEs14FRaxXosxy2zw==}
engines: {node: '>=14.18.0', npm: '>=8.0.0'}
hasBin: true
optionalDependencies:
/signal-exit@3.0.7:
resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==}
+ /signal-exit@4.0.1:
+ resolution: {integrity: sha512-uUWsN4aOxJAS8KOuf3QMyFtgm1pkb6I+KRZbRF/ghdf5T7sM+B1lLLzPDxswUjkmHyxQAVzEgG35E3NzDM9GVw==}
+ engines: {node: '>=14'}
+ dev: true
+
/signed-varint@2.0.1:
resolution: {integrity: sha512-abgDPg1106vuZZOvw7cFwdCABddfJRz5akcCcchzTbhyhYnsG31y4AlZEgp315T7W3nQq5P4xeOm186ZiPVFzw==}
dependencies:
source-map-support: 0.5.21
dev: true
- /terser@5.16.9:
- resolution: {integrity: sha512-HPa/FdTB9XGI2H1/keLFZHxl6WNvAI4YalHGtDQTlMnJcoqSab1UwL4l1hGEhs6/GmLHBZIg/YgB++jcbzoOEg==}
+ /terser@5.17.0:
+ resolution: {integrity: sha512-3die3+pYW4mta4xF6K8Wtf7id8+oYyfqtAhjwzqY01+CfDSDMx/VA1Sp8sXWs5AVNIoAKoUfmp/gnPqRjBxuDA==}
engines: {node: '>=10'}
hasBin: true
dependencies:
import { OCPP16ChargePointStatus } from '../../../types';
import { OCPPConstants } from '../internal';
+type Transition = { from?: OCPP16ChargePointStatus; to: OCPP16ChargePointStatus };
+
export class OCPP16Constants extends OCPPConstants {
- static readonly OCPP16ChargePointStatusChargingStationTransition = new Set<
- [OCPP16ChargePointStatus | undefined, OCPP16ChargePointStatus | undefined]
- >([
- [undefined, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Faulted],
- [undefined, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Faulted],
- [undefined, OCPP16ChargePointStatus.Faulted],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Unavailable],
- // [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Faulted],
- ]);
+ static readonly ChargePointStatusChargingStationTransitions: Transition[] = [
+ { to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Faulted },
+ { to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Faulted },
+ { to: OCPP16ChargePointStatus.Faulted },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Unavailable },
+ // { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Faulted },
+ ];
- static readonly OCPP16ChargePointStatusConnectorTransition = new Set<
- [OCPP16ChargePointStatus | undefined, OCPP16ChargePointStatus | undefined]
- >([
- [undefined, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.SuspendedEVSE],
- // [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Finishing],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Available, OCPP16ChargePointStatus.Faulted],
- // [undefined, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.SuspendedEVSE],
- [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Reserved],
- // [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Preparing, OCPP16ChargePointStatus.Faulted],
- // [undefined, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Preparing],
- // [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.SuspendedEVSE],
- [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Charging, OCPP16ChargePointStatus.Faulted],
- // [undefined, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Charging],
- // [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.SuspendedEVSE],
- [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.Faulted],
- // [undefined, OCPP16ChargePointStatus.SuspendedEVSE],
- [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Available],
- // [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.SuspendedEV],
- // [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.SuspendedEVSE],
- [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.SuspendedEVSE, OCPP16ChargePointStatus.Faulted],
- // [undefined, OCPP16ChargePointStatus.Finishing],
- [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Preparing],
- // [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Charging],
- // [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.SuspendedEV],
- // [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.SuspendedEVSE],
- // [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Finishing, OCPP16ChargePointStatus.Faulted],
- // [undefined, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Preparing],
- // [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Charging],
- // [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.SuspendedEV],
- // [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.SuspendedEVSE],
- // [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Reserved, OCPP16ChargePointStatus.Faulted],
- [undefined, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.SuspendedEVSE],
- // [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Finishing],
- // [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Reserved],
- // [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Unavailable],
- [OCPP16ChargePointStatus.Unavailable, OCPP16ChargePointStatus.Faulted],
- [undefined, OCPP16ChargePointStatus.Faulted],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Available],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Preparing],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Charging],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.SuspendedEV],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.SuspendedEVSE],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Finishing],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Reserved],
- [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Unavailable],
- // [OCPP16ChargePointStatus.Faulted, OCPP16ChargePointStatus.Faulted],
- ]);
+ static readonly ChargePointStatusConnectorTransitions: Transition[] = [
+ { to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ // { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Finishing },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Available, to: OCPP16ChargePointStatus.Faulted },
+ // { to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Reserved },
+ // { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Preparing, to: OCPP16ChargePointStatus.Faulted },
+ // { to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Preparing },
+ // { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Charging, to: OCPP16ChargePointStatus.Faulted },
+ // { to: OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Charging },
+ // { from: OCPP16ChargePointStatus.SuspendedEV, OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.SuspendedEV, to: OCPP16ChargePointStatus.Faulted },
+ // { to: OCPP16ChargePointStatus.SuspendedEVSE },
+ { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Available },
+ // { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.SuspendedEV },
+ // { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.SuspendedEVSE, to: OCPP16ChargePointStatus.Faulted },
+ // { to: OCPP16ChargePointStatus.Finishing},
+ { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Preparing },
+ // { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Charging },
+ // { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.SuspendedEV },
+ // { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ // { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Finishing, to: OCPP16ChargePointStatus.Faulted },
+ // { to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Preparing },
+ // { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Charging },
+ // { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.SuspendedEV },
+ // { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ // { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Reserved, to: OCPP16ChargePointStatus.Faulted },
+ { to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ // { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Finishing },
+ // { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Reserved },
+ // { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Unavailable },
+ { from: OCPP16ChargePointStatus.Unavailable, to: OCPP16ChargePointStatus.Faulted },
+ { to: OCPP16ChargePointStatus.Faulted },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Available },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Preparing },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Charging },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.SuspendedEV },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.SuspendedEVSE },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Finishing },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Reserved },
+ { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Unavailable },
+ // { from: OCPP16ChargePointStatus.Faulted, to: OCPP16ChargePointStatus.Faulted },
+ ];
}
--- /dev/null
+import { OCPP20ConnectorStatusEnumType } from '../../../types';
+import { OCPPConstants } from '../internal';
+
+type Transition = { from?: OCPP20ConnectorStatusEnumType; to: OCPP20ConnectorStatusEnumType };
+
+export class OCPP20Constants extends OCPPConstants {
+ static readonly ChargingStationStatusTransitions: Transition[] = [
+ { to: OCPP20ConnectorStatusEnumType.Available },
+ // { from: OCPP20ConnectorStatusEnumType.Available, to: OCPP20ConnectorStatusEnumType.Available },
+ {
+ from: OCPP20ConnectorStatusEnumType.Available,
+ to: OCPP20ConnectorStatusEnumType.Unavailable,
+ },
+ { from: OCPP20ConnectorStatusEnumType.Available, to: OCPP20ConnectorStatusEnumType.Faulted },
+ { to: OCPP20ConnectorStatusEnumType.Unavailable },
+ {
+ from: OCPP20ConnectorStatusEnumType.Unavailable,
+ to: OCPP20ConnectorStatusEnumType.Available,
+ },
+ // {
+ // from: OCPP20ConnectorStatusEnumType.Unavailable,
+ // to: OCPP20ConnectorStatusEnumType.Unavailable,
+ // },
+ { from: OCPP20ConnectorStatusEnumType.Unavailable, to: OCPP20ConnectorStatusEnumType.Faulted },
+ { to: OCPP20ConnectorStatusEnumType.Faulted },
+ { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Available },
+ { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Unavailable },
+ // { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Faulted },
+ ];
+
+ static readonly ConnectorStatusTransitions: Transition[] = [
+ { to: OCPP20ConnectorStatusEnumType.Available },
+ // { from: OCPP20ConnectorStatusEnumType.Available, to: OCPP20ConnectorStatusEnumType.Available },
+ { from: OCPP20ConnectorStatusEnumType.Available, to: OCPP20ConnectorStatusEnumType.Occupied },
+ { from: OCPP20ConnectorStatusEnumType.Available, to: OCPP20ConnectorStatusEnumType.Reserved },
+ {
+ from: OCPP20ConnectorStatusEnumType.Available,
+ to: OCPP20ConnectorStatusEnumType.Unavailable,
+ },
+ { from: OCPP20ConnectorStatusEnumType.Available, to: OCPP20ConnectorStatusEnumType.Faulted },
+ // { to: OCPP20ConnectorStatusEnumType.Occupied },
+ { from: OCPP20ConnectorStatusEnumType.Occupied, to: OCPP20ConnectorStatusEnumType.Available },
+ // { from: OCPP20ConnectorStatusEnumType.Occupied, to: OCPP20ConnectorStatusEnumType.Occupied },
+ // { from: OCPP20ConnectorStatusEnumType.Occupied, to: OCPP20ConnectorStatusEnumType.Reserved },
+ { from: OCPP20ConnectorStatusEnumType.Occupied, to: OCPP20ConnectorStatusEnumType.Unavailable },
+ { from: OCPP20ConnectorStatusEnumType.Occupied, to: OCPP20ConnectorStatusEnumType.Faulted },
+ // { to: OCPP20ConnectorStatusEnumType.Reserved },
+ { from: OCPP20ConnectorStatusEnumType.Reserved, to: OCPP20ConnectorStatusEnumType.Available },
+ { from: OCPP20ConnectorStatusEnumType.Reserved, to: OCPP20ConnectorStatusEnumType.Occupied },
+ // { from: OCPP20ConnectorStatusEnumType.Reserved, to: OCPP20ConnectorStatusEnumType.Reserved },
+ { from: OCPP20ConnectorStatusEnumType.Reserved, to: OCPP20ConnectorStatusEnumType.Unavailable },
+ { from: OCPP20ConnectorStatusEnumType.Reserved, to: OCPP20ConnectorStatusEnumType.Faulted },
+ { to: OCPP20ConnectorStatusEnumType.Unavailable },
+ {
+ from: OCPP20ConnectorStatusEnumType.Unavailable,
+ to: OCPP20ConnectorStatusEnumType.Available,
+ },
+ { from: OCPP20ConnectorStatusEnumType.Unavailable, to: OCPP20ConnectorStatusEnumType.Occupied },
+ // { from: OCPP20ConnectorStatusEnumType.Unavailable, to: OCPP20ConnectorStatusEnumType.Reserved },
+ // { from: OCPP20ConnectorStatusEnumType.Unavailable, to: OCPP20ConnectorStatusEnumType.Unavailable },
+ { from: OCPP20ConnectorStatusEnumType.Unavailable, to: OCPP20ConnectorStatusEnumType.Faulted },
+ { to: OCPP20ConnectorStatusEnumType.Faulted },
+ { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Available },
+ { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Occupied },
+ { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Reserved },
+ { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Unavailable },
+ // { from: OCPP20ConnectorStatusEnumType.Faulted, to: OCPP20ConnectorStatusEnumType.Faulted },
+ ];
+}