]> git.basschouten.com Git - openhab-addons.git/blob
6d316c61ba14474b8b880a3c65ad144c414e886e
[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.airvisualnode.internal.dto.airvisual;
14
15 import org.openhab.binding.airvisualnode.internal.dto.MeasurementsInterface;
16
17 import com.google.gson.annotations.SerializedName;
18
19 /**
20  * Measurements data.
21  *
22  * @author Victor Antonovich - Initial contribution
23  */
24 public class Measurements implements MeasurementsInterface {
25
26     private int co2Ppm;
27     @SerializedName("humidity_RH")
28     private int humidityRH;
29     @SerializedName("pm25_AQICN")
30     private int pm25AQICN;
31     @SerializedName("pm25_AQIUS")
32     private int pm25AQIUS;
33     private float pm25Ugm3;
34     @SerializedName("temperature_C")
35     private float temperatureC;
36     @SerializedName("temperature_F")
37     private float temperatureF;
38     private int vocPpb;
39
40     public Measurements(int co2Ppm, int humidityRH, int pm25AQICN, int pm25AQIUS, float pm25Ugm3, float temperatureC,
41             float temperatureF, int vocPpb) {
42         this.co2Ppm = co2Ppm;
43         this.humidityRH = humidityRH;
44         this.pm25AQICN = pm25AQICN;
45         this.pm25AQIUS = pm25AQIUS;
46         this.pm25Ugm3 = pm25Ugm3;
47         this.temperatureC = temperatureC;
48         this.temperatureF = temperatureF;
49         this.vocPpb = vocPpb;
50     }
51
52     @Override
53     public int getCo2Ppm() {
54         return co2Ppm;
55     }
56
57     public void setCo2Ppm(int co2Ppm) {
58         this.co2Ppm = co2Ppm;
59     }
60
61     @Override
62     public int getHumidityRH() {
63         return humidityRH;
64     }
65
66     public void setHumidityRH(int humidityRH) {
67         this.humidityRH = humidityRH;
68     }
69
70     @Override
71     public int getPm25AQICN() {
72         return pm25AQICN;
73     }
74
75     public void setPm25AQICN(int pm25AQICN) {
76         this.pm25AQICN = pm25AQICN;
77     }
78
79     @Override
80     public int getPm25AQIUS() {
81         return pm25AQIUS;
82     }
83
84     public void setPm25AQIUS(int pm25AQIUS) {
85         this.pm25AQIUS = pm25AQIUS;
86     }
87
88     @Override
89     public float getPm01Ugm3() {
90         return 0;
91     }
92
93     @Override
94     public float getPm10Ugm3() {
95         return 0;
96     }
97
98     @Override
99     public float getPm25Ugm3() {
100         return pm25Ugm3;
101     }
102
103     public void setPm25Ugm3(float pm25Ugm3) {
104         this.pm25Ugm3 = pm25Ugm3;
105     }
106
107     @Override
108     public float getTemperatureC() {
109         return temperatureC;
110     }
111
112     public void setTemperatureC(float temperatureC) {
113         this.temperatureC = temperatureC;
114     }
115
116     @Override
117     public float getTemperatureF() {
118         return temperatureF;
119     }
120
121     public void setTemperatureF(float temperatureF) {
122         this.temperatureF = temperatureF;
123     }
124
125     @Override
126     public int getVocPpb() {
127         return vocPpb;
128     }
129
130     public void setVocPpb(int vocPpb) {
131         this.vocPpb = vocPpb;
132     }
133 }