EvChargingMediatorService
Service responsible for providing access to e-Mobility Service Providers (eMSPs) in the system. One or more eMSPs may be available and can be used to charge the vehicle. There can be only a single eMSP authenticated at the same time.
Types
A data class that represents information on current battery charge level and remaining range.
Properties
Provides charging progress information including the current battery charge level and the current vehicle range. null
if the vehicle is not currently charging.
This will contain the details of the charging station requested by calling retrieveChargingStationDetails. When a session is started externally (e.g. through an app) this field will be updated with the ChargingStation from the active session of the authenticated eMSP.
The authentication status of each eMSP known to the system.
The properties of each eMSP known to the system.
Indicates if the charging cable is plugged into the vehicle.
Session information: session status, charging station id, charging point, and receipt of the charging session. This information will be updated during a session once more information is available.
Functions
Clear the currentChargingStation details. This will set currentChargingStation to null.
Concludes the charging session. This function ends the current charging session and resets the internal states. Should be called when a charging session has completed or there has been a failure.
Evaluates the approximated time Duration at the charging stop, allowing for some additional time needed to use the charging facility or null if one of function parameter requirements was not satisfied.
Request to start the authentication process for the specified eMSP. serviceIdentifiers are the keys returned by EvChargingMediatorService.emspInfo. The exact flow of events that form the authentication process is dependent upon the eMSP integration.
Request to log out of the eMSP service. The actual handling of this request should be implemented in the eMSP service plugin. See also EvChargingService.
Post a failure to the listeners of EvChargingEventListener. This should be called when a failure has happened during the charging process, and the failure is not handled by the callee.
Clients should call this API to inform the platform of the result of the authentication process initiated by logIn if the authentication process was Open ID.
Request to prepare the charging session. This method can be used by non-user interface components to request the user interface to show panels before actually charging.
This function will retrieve detailed information about the charging station. This information contains e.g. the charging points with its connectors and the tariffs and restrictions of the charging station. The resulting detailed information is stored in currentChargingStation.
Set the target percentage to which the battery should be charged during the current charging session. This target is not enforced by the EvChargingMediatorService.
Request the current charging progress information to be shown to the user. This method can be used by non-user interface components to request the user interface to show the current charging progress.
Initiate a charging session. The state of the current charging session can be monitored on sessionInfo.
Called when the user has interacted with the UI to stop an active charging session.