new EvVehicle(options)
BeNomad BeMap JavaScript API - EvVehicle (v1.5)
Single vehicle entry from `GET service/vehicle/1.1/findvehicles`. Mirrors
the v1.1 Java DTO at
`bemap_idea/.../service/v1_1_0/model/vehicle/VehicleInfo.java`. Every
field below comes verbatim from the plaintext wire response — no parsing
of formatted strings, no AES decryption.
Parameters:
| Name | Type | Description |
|---|---|---|
options |
Object | Parsed JSON entry from the server. |
Methods
(static) fromJson(json) → {bemap.EvVehicle}
Parse a raw vehicle JSON entry into an `EvVehicle`.
Parameters:
| Name | Type | Description |
|---|---|---|
json |
Object |
Returns:
- Type
- bemap.EvVehicle
getBatteryCapacity() → {Number|null}
Battery capacity in kWh, parsed from the server's `batteryName` field
(which arrives as a numeric-looking string like `"66"` or `"49"`).
Returns `null` when the field isn't numeric.
Returns:
- Type
- Number | null
getDatasheet() → {String|null}
Base64-encoded AES-encrypted datasheet blob, or `null` when the request
did not set `enableDatasheet: true` or the user lacks `ROLE_VEHICLE_DATASHEET`.
Decryption uses AES/ECB/PKCS5Padding with a shared key — out of scope
for this library; document the contract for power users.
Returns:
- Type
- String | null
getDimensions() → {Object|null}
Vehicle dimensions in centimetres, or `null` when not provided.
Returns:
- Type
- Object | null
getDisplayLabel() → {String}
Human-readable single-line summary built from the typed fields.
Useful for `
Returns:
- Type
- String