2 * Copyright (c) 2010-2023 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.mybmw.internal.dto.vehicle;
17 * derived from the API responses
19 * @author Martin Grassl - initial contribution
20 * @author Mark Herwege - refactoring, V2 API charging
22 public class ElectricChargingState {
23 private String chargingConnectionType = ""; // UNKNOWN,
24 private String chargingStatus = ""; // FINISHED_FULLY_CHARGED,
25 private boolean isChargerConnected = false; // true,
26 private int chargingTarget = -1; // 80,
27 private int chargingLevelPercent = -1; // 80,
28 private int remainingChargingMinutes = -1; // 178
29 private int range = -1; // 286
32 * @return the chargingConnectionType
34 public String getChargingConnectionType() {
35 return chargingConnectionType;
39 * @param chargingConnectionType the chargingConnectionType to set
41 public void setChargingConnectionType(String chargingConnectionType) {
42 this.chargingConnectionType = chargingConnectionType;
46 * @return the chargingStatus
48 public String getChargingStatus() {
49 return chargingStatus;
53 * @param chargingStatus the chargingStatus to set
55 public void setChargingStatus(String chargingStatus) {
56 this.chargingStatus = chargingStatus;
60 * @return the isChargerConnected
62 public boolean isChargerConnected() {
63 return isChargerConnected;
67 * @param isChargerConnected the isChargerConnected to set
69 public void setChargerConnected(boolean isChargerConnected) {
70 this.isChargerConnected = isChargerConnected;
74 * @return the chargingTarget
76 public int getChargingTarget() {
77 return chargingTarget;
81 * @param chargingTarget the chargingTarget to set
83 public void setChargingTarget(int chargingTarget) {
84 this.chargingTarget = chargingTarget;
88 * @return the chargingLevelPercent
90 public int getChargingLevelPercent() {
91 return chargingLevelPercent;
95 * @param chargingLevelPercent the chargingLevelPercent to set
97 public void setChargingLevelPercent(int chargingLevelPercent) {
98 this.chargingLevelPercent = chargingLevelPercent;
102 * @return the remainingChargingMinutes
104 public int getRemainingChargingMinutes() {
105 return remainingChargingMinutes;
109 * @param remainingChargingMinutes the remainingChargingMinutes to set
111 public void setRemainingChargingMinutes(int remainingChargingMinutes) {
112 this.remainingChargingMinutes = remainingChargingMinutes;
118 public int getRange() {
123 * @param range the range to set
125 public void setRange(int range) {
132 * @see java.lang.Object#toString()
136 public String toString() {
137 return "ElectricChargingState [chargingConnectionType=" + chargingConnectionType + ", chargingStatus="
138 + chargingStatus + ", isChargerConnected=" + isChargerConnected + ", chargingTarget=" + chargingTarget
139 + ", chargingLevelPercent=" + chargingLevelPercent + ", remainingChargingMinutes="
140 + remainingChargingMinutes + ", range=" + range + "]";