]> git.basschouten.com Git - openhab-addons.git/blob
f2466a0b9504207c9efecee824985acc34b6ec46
[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.livisismarthome.internal.client.api.entity.capability;
14
15 import org.openhab.binding.livisismarthome.internal.client.api.entity.state.BooleanStateDTO;
16 import org.openhab.binding.livisismarthome.internal.client.api.entity.state.DateTimeStateDTO;
17 import org.openhab.binding.livisismarthome.internal.client.api.entity.state.DoubleStateDTO;
18 import org.openhab.binding.livisismarthome.internal.client.api.entity.state.IntegerStateDTO;
19 import org.openhab.binding.livisismarthome.internal.client.api.entity.state.StringStateDTO;
20
21 import com.google.gson.annotations.SerializedName;
22
23 /**
24  * Holds the Capability state.
25  *
26  * @author Oliver Kuhl - Initial contribution
27  *
28  */
29 public class StateDTO {
30
31     @SerializedName("absoluteEnergyConsumption")
32     private DoubleStateDTO absoluteEnergyConsumptionState;
33
34     @SerializedName("activeChannel")
35     private StringStateDTO activeChannelState;
36
37     @SerializedName("dimLevel")
38     private IntegerStateDTO dimLevelState;
39
40     @SerializedName("energyConsumptionDayEuro")
41     private DoubleStateDTO energyConsumptionDayEuroState;
42
43     @SerializedName("energyConsumptionDayKWh")
44     private DoubleStateDTO energyConsumptionDayKWhState;
45
46     @SerializedName("energyConsumptionMonthEuro")
47     private DoubleStateDTO energyConsumptionMonthEuroState;
48
49     @SerializedName("energyConsumptionMonthKWh")
50     private DoubleStateDTO energyConsumptionMonthKWhState;
51
52     @SerializedName("energyPerDayInEuro")
53     private DoubleStateDTO energyPerDayInEuroState;
54
55     @SerializedName("energyPerDayInKWh")
56     private DoubleStateDTO energyPerDayInKWhState;
57
58     @SerializedName("energyPerMonthInEuro")
59     private DoubleStateDTO energyPerMonthInEuroState;
60
61     @SerializedName("energyPerMonthInKWh")
62     private DoubleStateDTO energyPerMonthInKWhState;
63
64     @SerializedName("frostWarning")
65     private BooleanStateDTO frostWarningState;
66
67     @SerializedName("humidity")
68     private DoubleStateDTO humidityState;
69
70     @SerializedName("isDay")
71     private BooleanStateDTO isDayState;
72
73     @SerializedName("isOn")
74     private BooleanStateDTO isOnState;
75
76     @SerializedName("isOpen")
77     private BooleanStateDTO isOpenState;
78
79     @SerializedName("isSmokeAlarm")
80     private BooleanStateDTO isSmokeAlarmState;
81
82     @SerializedName("lastKeyPressCounter")
83     private IntegerStateDTO lastKeyPressCounterState;
84
85     @SerializedName("lastPressedButtonIndex")
86     private IntegerStateDTO lastPressedButtonIndex;
87
88     private StringStateDTO lastPressedButtonIndexState;
89
90     @SerializedName("luminance")
91     private DoubleStateDTO luminanceState;
92
93     @SerializedName("moldWarning")
94     private BooleanStateDTO moldWarningState;
95
96     @SerializedName("motionDetectedCount")
97     private IntegerStateDTO motionDetectedCountState;
98
99     @SerializedName("nextSunrise")
100     private DateTimeStateDTO nextSunrise;
101
102     @SerializedName("nextSunset")
103     private DateTimeStateDTO nextSunsetState;
104
105     @SerializedName("nextTimeEvent")
106     private DateTimeStateDTO nextTimeEventState;
107
108     @SerializedName("onState")
109     private BooleanStateDTO onState;
110
111     @SerializedName("operationMode")
112     private StringStateDTO operationModeState;
113
114     @SerializedName("pointTemperature")
115     private DoubleStateDTO pointTemperatureState;
116
117     @SerializedName("powerConsumptionWatt")
118     private DoubleStateDTO powerConsumptionWattState;
119
120     @SerializedName("powerInWatt")
121     private DoubleStateDTO powerInWattState;
122
123     @SerializedName("shutterLevel")
124     private IntegerStateDTO shutterLevelState;
125
126     @SerializedName("supplyValueInCubicMetterPerDay")
127     private DoubleStateDTO supplyValueInCubicMetterPerDayState;
128
129     @SerializedName("supplyValueInCubicMetterPerMonth")
130     private DoubleStateDTO supplyValueInCubicMetterPerMonthState;
131
132     @SerializedName("supplyValueInCurrencyPerDay")
133     private DoubleStateDTO supplyValueInCurrencyPerDayState;
134
135     @SerializedName("supplyValueInCurrencyPerMonth")
136     private DoubleStateDTO supplyValueInCurrencyPerMonthState;
137
138     @SerializedName("supplyValueInLitrePerDay")
139     private DoubleStateDTO supplyValueInLitrePerDayState;
140
141     @SerializedName("supplyValueInLitrePerMonth")
142     private DoubleStateDTO supplyValueInLitrePerMonthState;
143
144     @SerializedName("temperature")
145     private DoubleStateDTO temperatureState;
146
147     @SerializedName("totalEnergy")
148     private DoubleStateDTO totalEnergyState;
149
150     @SerializedName("value")
151     private BooleanStateDTO valueState;
152
153     @SerializedName("valvePosition")
154     private BooleanStateDTO valvePositionState;
155
156     @SerializedName("windowReductionActive")
157     private BooleanStateDTO windowReductionActiveState;
158
159     public StateDTO() {
160         absoluteEnergyConsumptionState = new DoubleStateDTO();
161         activeChannelState = new StringStateDTO();
162         dimLevelState = new IntegerStateDTO();
163         energyConsumptionDayEuroState = new DoubleStateDTO();
164         energyConsumptionDayKWhState = new DoubleStateDTO();
165         energyConsumptionMonthEuroState = new DoubleStateDTO();
166         energyConsumptionMonthKWhState = new DoubleStateDTO();
167         energyPerDayInEuroState = new DoubleStateDTO();
168         energyPerDayInKWhState = new DoubleStateDTO();
169         energyPerMonthInEuroState = new DoubleStateDTO();
170         energyPerMonthInKWhState = new DoubleStateDTO();
171         frostWarningState = new BooleanStateDTO();
172         humidityState = new DoubleStateDTO();
173         isDayState = new BooleanStateDTO();
174         isOnState = new BooleanStateDTO();
175         isOpenState = new BooleanStateDTO();
176         isSmokeAlarmState = new BooleanStateDTO();
177         lastKeyPressCounterState = new IntegerStateDTO();
178         lastPressedButtonIndex = new IntegerStateDTO();
179         lastPressedButtonIndexState = new StringStateDTO();
180         luminanceState = new DoubleStateDTO();
181         moldWarningState = new BooleanStateDTO();
182         motionDetectedCountState = new IntegerStateDTO();
183         nextSunrise = new DateTimeStateDTO();
184         nextSunsetState = new DateTimeStateDTO();
185         nextTimeEventState = new DateTimeStateDTO();
186         onState = new BooleanStateDTO();
187         operationModeState = new StringStateDTO();
188         pointTemperatureState = new DoubleStateDTO();
189         powerConsumptionWattState = new DoubleStateDTO();
190         powerInWattState = new DoubleStateDTO();
191         shutterLevelState = new IntegerStateDTO();
192         supplyValueInCubicMetterPerDayState = new DoubleStateDTO();
193         supplyValueInCubicMetterPerMonthState = new DoubleStateDTO();
194         supplyValueInCurrencyPerDayState = new DoubleStateDTO();
195         supplyValueInCurrencyPerMonthState = new DoubleStateDTO();
196         supplyValueInLitrePerDayState = new DoubleStateDTO();
197         supplyValueInLitrePerMonthState = new DoubleStateDTO();
198         temperatureState = new DoubleStateDTO();
199         totalEnergyState = new DoubleStateDTO();
200         valueState = new BooleanStateDTO();
201         valvePositionState = new BooleanStateDTO();
202         windowReductionActiveState = new BooleanStateDTO();
203     }
204
205     /**
206      * @return the absoluteEnergyConsumptionState
207      */
208     public DoubleStateDTO getAbsoluteEnergyConsumptionState() {
209         return absoluteEnergyConsumptionState;
210     }
211
212     /**
213      * @param state the absoluteEnergyConsumptionState to set
214      */
215     public void setAbsoluteEnergyConsumptionState(DoubleStateDTO state) {
216         this.absoluteEnergyConsumptionState = state;
217     }
218
219     /**
220      * @return the activeChannelState
221      */
222     public StringStateDTO getActiveChannelState() {
223         return activeChannelState;
224     }
225
226     /**
227      * @param state the activeChannelState to set
228      */
229     public void setActiveChannelState(StringStateDTO state) {
230         this.activeChannelState = state;
231     }
232
233     /**
234      * @return the dimLevelState
235      */
236     public IntegerStateDTO getDimLevelState() {
237         return dimLevelState;
238     }
239
240     /**
241      * @param state the dimLevelState to set
242      */
243     public void setDimLevelState(IntegerStateDTO state) {
244         this.dimLevelState = state;
245     }
246
247     /**
248      * @return the energyConsumptionDayEuroState
249      */
250     public DoubleStateDTO getEnergyConsumptionDayEuroState() {
251         return energyConsumptionDayEuroState;
252     }
253
254     /**
255      * @param state the energyConsumptionDayEuroState to set
256      */
257     public void setEnergyConsumptionDayEuroState(DoubleStateDTO state) {
258         this.energyConsumptionDayEuroState = state;
259     }
260
261     /**
262      * @return the energyConsumptionDayKWhState
263      */
264     public DoubleStateDTO getEnergyConsumptionDayKWhState() {
265         return energyConsumptionDayKWhState;
266     }
267
268     /**
269      * @param state the energyConsumptionDayKWhState to set
270      */
271     public void setEnergyConsumptionDayKWhState(DoubleStateDTO state) {
272         this.energyConsumptionDayKWhState = state;
273     }
274
275     /**
276      * @return the energyConsumptionMonthEuroState
277      */
278     public DoubleStateDTO getEnergyConsumptionMonthEuroState() {
279         return energyConsumptionMonthEuroState;
280     }
281
282     /**
283      * @param state the energyConsumptionMonthEuroState to set
284      */
285     public void setEnergyConsumptionMonthEuroState(DoubleStateDTO state) {
286         this.energyConsumptionMonthEuroState = state;
287     }
288
289     /**
290      * @return the energyConsumptionMonthKWhState
291      */
292     public DoubleStateDTO getEnergyConsumptionMonthKWhState() {
293         return energyConsumptionMonthKWhState;
294     }
295
296     /**
297      * @param state the energyConsumptionMonthKWhState to set
298      */
299     public void setEnergyConsumptionMonthKWhState(DoubleStateDTO state) {
300         this.energyConsumptionMonthKWhState = state;
301     }
302
303     /**
304      * @return the energyPerDayInEuroState
305      */
306     public DoubleStateDTO getEnergyPerDayInEuroState() {
307         return energyPerDayInEuroState;
308     }
309
310     /**
311      * @param state the energyPerDayInEuroState to set
312      */
313     public void setEnergyPerDayInEuroState(DoubleStateDTO state) {
314         this.energyPerDayInEuroState = state;
315     }
316
317     /**
318      * @return the energyPerDayInKWhState
319      */
320     public DoubleStateDTO getEnergyPerDayInKWhState() {
321         return energyPerDayInKWhState;
322     }
323
324     /**
325      * @param state the energyPerDayInKWhState to set
326      */
327     public void setEnergyPerDayInKWhState(DoubleStateDTO state) {
328         this.energyPerDayInKWhState = state;
329     }
330
331     /**
332      * @return the energyPerMonthInEuroState
333      */
334     public DoubleStateDTO getEnergyPerMonthInEuroState() {
335         return energyPerMonthInEuroState;
336     }
337
338     /**
339      * @param state the energyPerMonthInEuroState to set
340      */
341     public void setEnergyPerMonthInEuroState(DoubleStateDTO state) {
342         this.energyPerMonthInEuroState = state;
343     }
344
345     /**
346      * @return the energyPerMonthInKWhState
347      */
348     public DoubleStateDTO getEnergyPerMonthInKWhState() {
349         return energyPerMonthInKWhState;
350     }
351
352     /**
353      * @param state the energyPerMonthInKWhState to set
354      */
355     public void setEnergyPerMonthInKWhState(DoubleStateDTO state) {
356         this.energyPerMonthInKWhState = state;
357     }
358
359     /**
360      * @return the frostWarningState
361      */
362     public BooleanStateDTO getFrostWarningState() {
363         return frostWarningState;
364     }
365
366     /**
367      * @param state the frostWarningState to set
368      */
369     public void setFrostWarningState(BooleanStateDTO state) {
370         this.frostWarningState = state;
371     }
372
373     /**
374      * @return the humidityState
375      */
376     public DoubleStateDTO getHumidityState() {
377         return humidityState;
378     }
379
380     /**
381      * @param state the humidityState to set
382      */
383     public void setHumidityState(DoubleStateDTO state) {
384         this.humidityState = state;
385     }
386
387     /**
388      * @return the isDayState
389      */
390     public BooleanStateDTO getIsDayState() {
391         return isDayState;
392     }
393
394     /**
395      * @param state the isDayState to set
396      */
397     public void setIsDayState(BooleanStateDTO state) {
398         this.isDayState = state;
399     }
400
401     /**
402      * @return the isOnState
403      */
404     public BooleanStateDTO getIsOnState() {
405         return isOnState;
406     }
407
408     /**
409      * @param state the isOnState to set
410      */
411     public void setIsOnState(BooleanStateDTO state) {
412         this.isOnState = state;
413     }
414
415     /**
416      * @return the isOpenState
417      */
418     public BooleanStateDTO getIsOpenState() {
419         return isOpenState;
420     }
421
422     /**
423      * @param state the isOpenState to set
424      */
425     public void setIsOpenState(BooleanStateDTO state) {
426         this.isOpenState = state;
427     }
428
429     /**
430      * @return the isSmokeAlarmState
431      */
432     public BooleanStateDTO getIsSmokeAlarmState() {
433         return isSmokeAlarmState;
434     }
435
436     /**
437      * @param state the isSmokeAlarmState to set
438      */
439     public void setIsSmokeAlarmState(BooleanStateDTO state) {
440         this.isSmokeAlarmState = state;
441     }
442
443     /**
444      * @return the lastKeyPressCounterState
445      */
446     public IntegerStateDTO getLastKeyPressCounterState() {
447         return lastKeyPressCounterState;
448     }
449
450     /**
451      * @param state the lastKeyPressCounterState to set
452      */
453     public void setLastKeyPressCounterState(IntegerStateDTO state) {
454         this.lastKeyPressCounterState = state;
455     }
456
457     /**
458      * @return the lastPressedButtonIndex
459      */
460     public IntegerStateDTO getLastPressedButtonIndex() {
461         return lastPressedButtonIndex;
462     }
463
464     /**
465      * @param state the lastPressedButtonIndex to set
466      */
467     public void setLastPressedButtonIndex(IntegerStateDTO state) {
468         this.lastPressedButtonIndex = state;
469     }
470
471     public StringStateDTO getLastKeyPressType() {
472         if (lastPressedButtonIndexState == null) {
473             lastPressedButtonIndexState = new StringStateDTO();
474         }
475         return lastPressedButtonIndexState;
476     }
477
478     public void setLastKeyPressType(StringStateDTO lastPressedButtonIndexState) {
479         this.lastPressedButtonIndexState = lastPressedButtonIndexState;
480     }
481
482     /**
483      * @return the luminanceState
484      */
485     public DoubleStateDTO getLuminanceState() {
486         return luminanceState;
487     }
488
489     /**
490      * @param state the luminanceState to set
491      */
492     public void setLuminanceState(DoubleStateDTO state) {
493         this.luminanceState = state;
494     }
495
496     /**
497      * @return the moldWarningState
498      */
499     public BooleanStateDTO getMoldWarningState() {
500         return moldWarningState;
501     }
502
503     /**
504      * @param state the moldWarningState to set
505      */
506     public void setMoldWarningState(BooleanStateDTO state) {
507         this.moldWarningState = state;
508     }
509
510     /**
511      * @return the motionDetectedCountState
512      */
513     public IntegerStateDTO getMotionDetectedCountState() {
514         return motionDetectedCountState;
515     }
516
517     /**
518      * @param state the motionDetectedCountState to set
519      */
520     public void setMotionDetectedCountState(IntegerStateDTO state) {
521         this.motionDetectedCountState = state;
522     }
523
524     /**
525      * @return the nextSunrise
526      */
527     public DateTimeStateDTO getNextSunrise() {
528         return nextSunrise;
529     }
530
531     /**
532      * @param state the nextSunrise to set
533      */
534     public void setNextSunrise(DateTimeStateDTO state) {
535         this.nextSunrise = state;
536     }
537
538     /**
539      * @return the nextSunsetState
540      */
541     public DateTimeStateDTO getNextSunsetState() {
542         return nextSunsetState;
543     }
544
545     /**
546      * @param state the nextSunsetState to set
547      */
548     public void setNextSunsetState(DateTimeStateDTO state) {
549         this.nextSunsetState = state;
550     }
551
552     /**
553      * @return the nextTimeEventState
554      */
555     public DateTimeStateDTO getNextTimeEventState() {
556         return nextTimeEventState;
557     }
558
559     /**
560      * @param state the nextTimeEventState to set
561      */
562     public void setNextTimeEventState(DateTimeStateDTO state) {
563         this.nextTimeEventState = state;
564     }
565
566     /**
567      * @return the onState
568      */
569     public BooleanStateDTO getOnState() {
570         return onState;
571     }
572
573     /**
574      * @param state the onState to set
575      */
576     public void setOnState(BooleanStateDTO state) {
577         this.onState = state;
578     }
579
580     /**
581      * @return the operationModeState
582      */
583     public StringStateDTO getOperationModeState() {
584         return operationModeState;
585     }
586
587     /**
588      * @param state the operationModeState to set
589      */
590     public void setOperationModeState(StringStateDTO state) {
591         this.operationModeState = state;
592     }
593
594     /**
595      * @return the pointTemperatureState
596      */
597     public DoubleStateDTO getPointTemperatureState() {
598         return pointTemperatureState;
599     }
600
601     /**
602      * @param state the pointTemperatureState to set
603      */
604     public void setPointTemperatureState(DoubleStateDTO state) {
605         this.pointTemperatureState = state;
606     }
607
608     /**
609      * @return the powerConsumptionWattState
610      */
611     public DoubleStateDTO getPowerConsumptionWattState() {
612         return powerConsumptionWattState;
613     }
614
615     /**
616      * @param state the powerConsumptionWattState to set
617      */
618     public void setPowerConsumptionWattState(DoubleStateDTO state) {
619         this.powerConsumptionWattState = state;
620     }
621
622     /**
623      * @return the powerInWattState
624      */
625     public DoubleStateDTO getPowerInWattState() {
626         return powerInWattState;
627     }
628
629     /**
630      * @param state the powerInWattState to set
631      */
632     public void setPowerInWattState(DoubleStateDTO state) {
633         this.powerInWattState = state;
634     }
635
636     /**
637      * @return the shutterLevelState
638      */
639     public IntegerStateDTO getShutterLevelState() {
640         return shutterLevelState;
641     }
642
643     /**
644      * @param state the shutterLevelState to set
645      */
646     public void setShutterLevelState(IntegerStateDTO state) {
647         this.shutterLevelState = state;
648     }
649
650     /**
651      * @return the supplyValueInCubicMetterPerDayState
652      */
653     public DoubleStateDTO getSupplyValueInCubicMetterPerDayState() {
654         return supplyValueInCubicMetterPerDayState;
655     }
656
657     /**
658      * @param state the supplyValueInCubicMetterPerDayState to set
659      */
660     public void setSupplyValueInCubicMetterPerDayState(DoubleStateDTO state) {
661         this.supplyValueInCubicMetterPerDayState = state;
662     }
663
664     /**
665      * @return the supplyValueInCubicMetterPerMonthState
666      */
667     public DoubleStateDTO getSupplyValueInCubicMetterPerMonthState() {
668         return supplyValueInCubicMetterPerMonthState;
669     }
670
671     /**
672      * @param state the supplyValueInCubicMetterPerMonthState to set
673      */
674     public void setSupplyValueInCubicMetterPerMonthState(DoubleStateDTO state) {
675         this.supplyValueInCubicMetterPerMonthState = state;
676     }
677
678     /**
679      * @return the supplyValueInCurrencyPerDayState
680      */
681     public DoubleStateDTO getSupplyValueInCurrencyPerDayState() {
682         return supplyValueInCurrencyPerDayState;
683     }
684
685     /**
686      * @param state the supplyValueInCurrencyPerDayState to set
687      */
688     public void setSupplyValueInCurrencyPerDayState(DoubleStateDTO state) {
689         this.supplyValueInCurrencyPerDayState = state;
690     }
691
692     /**
693      * @return the supplyValueInCurrencyPerMonthState
694      */
695     public DoubleStateDTO getSupplyValueInCurrencyPerMonthState() {
696         return supplyValueInCurrencyPerMonthState;
697     }
698
699     /**
700      * @param state the supplyValueInCurrencyPerMonthState to set
701      */
702     public void setSupplyValueInCurrencyPerMonthState(DoubleStateDTO state) {
703         this.supplyValueInCurrencyPerMonthState = state;
704     }
705
706     /**
707      * @return the supplyValueInLitrePerDayState
708      */
709     public DoubleStateDTO getSupplyValueInLitrePerDayState() {
710         return supplyValueInLitrePerDayState;
711     }
712
713     /**
714      * @param state the supplyValueInLitrePerDayState to set
715      */
716     public void setSupplyValueInLitrePerDayState(DoubleStateDTO state) {
717         this.supplyValueInLitrePerDayState = state;
718     }
719
720     /**
721      * @return the supplyValueInLitrePerMonthState
722      */
723     public DoubleStateDTO getSupplyValueInLitrePerMonthState() {
724         return supplyValueInLitrePerMonthState;
725     }
726
727     /**
728      * @param state the supplyValueInLitrePerMonthState to set
729      */
730     public void setSupplyValueInLitrePerMonthState(DoubleStateDTO state) {
731         this.supplyValueInLitrePerMonthState = state;
732     }
733
734     /**
735      * @return the temperatureState
736      */
737     public DoubleStateDTO getTemperatureState() {
738         return temperatureState;
739     }
740
741     /**
742      * @param state the temperatureState to set
743      */
744     public void setTemperatureState(DoubleStateDTO state) {
745         this.temperatureState = state;
746     }
747
748     /**
749      * @return the totalEnergyState
750      */
751     public DoubleStateDTO getTotalEnergyState() {
752         return totalEnergyState;
753     }
754
755     /**
756      * @param state the totalEnergyState to set
757      */
758     public void setTotalEnergyState(DoubleStateDTO state) {
759         this.totalEnergyState = state;
760     }
761
762     /**
763      * @return the valueState
764      */
765     public BooleanStateDTO getValueState() {
766         return valueState;
767     }
768
769     /**
770      * @param state the valueState to set
771      */
772     public void setValueState(BooleanStateDTO state) {
773         this.valueState = state;
774     }
775
776     /**
777      * @return the valvePositionState
778      */
779     public BooleanStateDTO getValvePositionState() {
780         return valvePositionState;
781     }
782
783     /**
784      * @param state the valvePositionState to set
785      */
786     public void setValvePositionState(BooleanStateDTO state) {
787         this.valvePositionState = state;
788     }
789
790     /**
791      * @return the windowReductionActiveState
792      */
793     public BooleanStateDTO getWindowReductionActiveState() {
794         return windowReductionActiveState;
795     }
796
797     /**
798      * @param state the windowReductionActiveState to set
799      */
800     public void setWindowReductionActiveState(BooleanStateDTO state) {
801         this.windowReductionActiveState = state;
802     }
803 }