2 * Copyright (c) 2010-2024 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.electroluxair.internal.dto;
15 import java.util.HashMap;
18 import org.eclipse.jdt.annotation.NonNullByDefault;
20 import com.google.gson.annotations.SerializedName;
23 * The {@link ElectroluxPureA9DTO} class defines the DTO for the Electrolux Pure A9.
25 * @author Jan Gustafsson - Initial contribution
28 public class ElectroluxPureA9DTO {
29 private String applianceId = "";
30 private ApplianceInfo applianceInfo = new ApplianceInfo();
31 private ApplianceData applianceData = new ApplianceData();
32 private Properties properties = new Properties();
33 private String status = "";
34 private String connectionState = "";
36 public String getApplianceId() {
40 public ApplianceInfo getApplianceInfo() {
44 public void setApplianceInfo(ApplianceInfo applianceInfo) {
45 this.applianceInfo = applianceInfo;
48 public ApplianceData getApplianceData() {
52 public Properties getProperties() {
56 public String getStatus() {
60 public String getConnectionState() {
61 return connectionState;
64 public class ApplianceInfo {
65 private String manufacturingDateCode = "";
66 private String serialNumber = "";
67 private String pnc = "";
68 private String brand = "";
69 private String market = "";
70 private String productArea = "";
71 private String deviceType = "";
72 private String project = "";
73 private String model = "";
74 private String variant = "";
75 private String colour = "";
77 public String getManufacturingDateCode() {
78 return manufacturingDateCode;
81 public String getSerialNumber() {
85 public String getPnc() {
89 public String getBrand() {
93 public String getMarket() {
97 public String getProductArea() {
101 public String getDeviceType() {
105 public String getProject() {
109 public String getModel() {
113 public String getVariant() {
117 public String getColour() {
122 class ApplianceData {
123 private String applianceName = "";
124 private String created = "";
125 private String modelName = "";
127 public String getApplianceName() {
128 return applianceName;
131 public String getCreated() {
135 public String getModelName() {
140 public class Properties {
141 private Desired desired = new Desired();
142 private Reported reported = new Reported();
143 private Object metadata = new Object();
145 public Desired getDesired() {
149 public Reported getReported() {
153 public Object getMetadata() {
159 @SerializedName("TimeZoneStandardName")
160 private String timeZoneStandardName = "";
161 @SerializedName("FrmVer_NIU")
162 private String frmVerNIU = "";
163 @SerializedName("LocationReq")
164 private boolean locationReq;
165 private Map<String, Object> metadata = new HashMap<>();
168 public String getTimeZoneStandardName() {
169 return timeZoneStandardName;
172 public String getFrmVerNIU() {
176 public boolean isLocationReq() {
180 public Map<String, Object> getMetadata() {
184 public int getVersion() {
189 public class Reported {
190 @SerializedName("FrmVer_NIU")
191 private String frmVerNIU = "";
192 @SerializedName("Workmode")
193 private String workmode = "";
194 @SerializedName("FilterRFID")
195 private String filterRFID = "";
196 @SerializedName("FilterLife")
197 private int filterLife = 0;
198 @SerializedName("Fanspeed")
199 private int fanSpeed = 0;
200 @SerializedName("UILight")
201 private boolean uiLight = false;
202 @SerializedName("SafetyLock")
203 private boolean safetyLock = false;
204 @SerializedName("Ionizer")
205 private boolean ionizer = false;
206 @SerializedName("Sleep")
207 private boolean sleep = false;
208 @SerializedName("Scheduler")
209 private boolean scheduler = false;
210 @SerializedName("FilterType")
211 private int filterType = 0;
212 @SerializedName("DspIcoPM2_5")
213 private boolean dspIcoPM25 = false;
214 @SerializedName("DspIcoPM1")
215 private boolean dspIcoPM1 = false;
216 @SerializedName("DspIcoPM10")
217 private boolean dspIcoPM10 = false;
218 @SerializedName("DspIcoTVOC")
219 private boolean dspIcoTVOC = false;
220 @SerializedName("ErrPM2_5")
221 private boolean errPM25 = false;
222 @SerializedName("ErrTVOC")
223 private boolean errTVOC = false;
224 @SerializedName("ErrTempHumidity")
225 private boolean errTempHumidity = false;
226 @SerializedName("ErrFanMtr")
227 private boolean errFanMtr = false;
228 @SerializedName("ErrCommSensorDisplayBrd")
229 private boolean errCommSensorDisplayBrd = false;
230 @SerializedName("DoorOpen")
231 private boolean doorOpen = false;
232 @SerializedName("ErrRFID")
233 private boolean errRFID = false;
234 @SerializedName("SignalStrength")
235 private String signalStrength = "";
236 private Map<String, Object> metadata = new HashMap<>();
237 private int version = 0;
238 private String deviceId = "";
239 @SerializedName("CO2")
241 @SerializedName("TVOC")
242 private int tvoc = 0;
243 @SerializedName("Temp")
244 private int temp = 0;
245 @SerializedName("Humidity")
246 private int humidity = 0;
247 @SerializedName("RSSI")
248 private int rssi = 0;
249 @SerializedName("PM1")
251 @SerializedName("PM2_5")
252 private int pm25 = 0;
253 @SerializedName("PM10")
254 private int pm10 = 0;
256 public String getFrmVerNIU() {
260 public String getWorkmode() {
264 public String getFilterRFID() {
268 public int getFilterLife() {
272 public int getFanspeed() {
276 public boolean isUILight() {
280 public boolean isSafetyLock() {
284 public boolean isIonizer() {
288 public boolean isSleep() {
292 public boolean isScheduler() {
296 public int getFilterType() {
300 public boolean isDspIcoPM25() {
304 public boolean isDspIcoPM1() {
308 public boolean isDspIcoPM10() {
312 public boolean isDspIcoTVOC() {
316 public boolean isErrPM25() {
320 public boolean isErrTVOC() {
324 public boolean isErrTempHumidity() {
325 return errTempHumidity;
328 public boolean isErrFanMtr() {
332 public boolean isErrCommSensorDisplayBrd() {
333 return errCommSensorDisplayBrd;
336 public boolean isDoorOpen() {
340 public boolean isErrRFID() {
344 public String getSignalStrength() {
345 return signalStrength;
348 public Map<String, Object> getMetadata() {
352 public int getVersion() {
356 public String getDeviceId() {
360 public int getCO2() {
364 public int getTVOC() {
368 public int getTemp() {
372 public int getHumidity() {
376 public int getRSSI() {
380 public int getPM1() {
384 public int getPM25() {
388 public int getPM10() {