]> git.basschouten.com Git - openhab-addons.git/blob
e49dc0aa490577b65724967ccdeb939e9bd86f4e
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2023 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
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
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.mybmw.internal.dto.vehicle;
14
15 /**
16  *
17  * derived from the API responses
18  *
19  * @author Martin Grassl - initial contribution
20  * @author Mark Herwege - refactoring, V2 API charging
21  */
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
30
31     /**
32      * @return the chargingConnectionType
33      */
34     public String getChargingConnectionType() {
35         return chargingConnectionType;
36     }
37
38     /**
39      * @param chargingConnectionType the chargingConnectionType to set
40      */
41     public void setChargingConnectionType(String chargingConnectionType) {
42         this.chargingConnectionType = chargingConnectionType;
43     }
44
45     /**
46      * @return the chargingStatus
47      */
48     public String getChargingStatus() {
49         return chargingStatus;
50     }
51
52     /**
53      * @param chargingStatus the chargingStatus to set
54      */
55     public void setChargingStatus(String chargingStatus) {
56         this.chargingStatus = chargingStatus;
57     }
58
59     /**
60      * @return the isChargerConnected
61      */
62     public boolean isChargerConnected() {
63         return isChargerConnected;
64     }
65
66     /**
67      * @param isChargerConnected the isChargerConnected to set
68      */
69     public void setChargerConnected(boolean isChargerConnected) {
70         this.isChargerConnected = isChargerConnected;
71     }
72
73     /**
74      * @return the chargingTarget
75      */
76     public int getChargingTarget() {
77         return chargingTarget;
78     }
79
80     /**
81      * @param chargingTarget the chargingTarget to set
82      */
83     public void setChargingTarget(int chargingTarget) {
84         this.chargingTarget = chargingTarget;
85     }
86
87     /**
88      * @return the chargingLevelPercent
89      */
90     public int getChargingLevelPercent() {
91         return chargingLevelPercent;
92     }
93
94     /**
95      * @param chargingLevelPercent the chargingLevelPercent to set
96      */
97     public void setChargingLevelPercent(int chargingLevelPercent) {
98         this.chargingLevelPercent = chargingLevelPercent;
99     }
100
101     /**
102      * @return the remainingChargingMinutes
103      */
104     public int getRemainingChargingMinutes() {
105         return remainingChargingMinutes;
106     }
107
108     /**
109      * @param remainingChargingMinutes the remainingChargingMinutes to set
110      */
111     public void setRemainingChargingMinutes(int remainingChargingMinutes) {
112         this.remainingChargingMinutes = remainingChargingMinutes;
113     }
114
115     /**
116      * @return the range
117      */
118     public int getRange() {
119         return range;
120     }
121
122     /**
123      * @param range the range to set
124      */
125     public void setRange(int range) {
126         this.range = range;
127     }
128
129     /*
130      * (non-Javadoc)
131      *
132      * @see java.lang.Object#toString()
133      */
134
135     @Override
136     public String toString() {
137         return "ElectricChargingState [chargingConnectionType=" + chargingConnectionType + ", chargingStatus="
138                 + chargingStatus + ", isChargerConnected=" + isChargerConnected + ", chargingTarget=" + chargingTarget
139                 + ", chargingLevelPercent=" + chargingLevelPercent + ", remainingChargingMinutes="
140                 + remainingChargingMinutes + ", range=" + range + "]";
141     }
142 }