]> git.basschouten.com Git - openhab-addons.git/blob
be79e1bda9dfe245517db2f874ca0859a8106e65
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2021 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.openweathermap.internal.dto.onecall;
14
15 import java.util.List;
16
17 import org.eclipse.jdt.annotation.Nullable;
18
19 import com.google.gson.annotations.SerializedName;
20
21 /**
22  * Holds the data from the deserialised JSON response. Created using http://www.jsonschema2pojo.org/.
23  * Settings:
24  * Annotation Style: GSON
25  * Use primitive types
26  * Use double numbers
27  * allow additional properties
28  *
29  * @author Wolfgang Klimt - Initial contribution
30  * @author Christoph Weitkamp - Added weather alerts
31  */
32 public class OpenWeatherMapOneCallAPIData {
33
34     private double lat;
35     private double lon;
36     private String timezone;
37     @SerializedName("timezone_offset")
38     private int timezoneOffset;
39     private Current current;
40     private List<Minutely> minutely;
41     private List<Hourly> hourly;
42     private List<Daily> daily;
43
44     public @Nullable List<Alert> alerts;
45
46     public double getLat() {
47         return lat;
48     }
49
50     public void setLat(double lat) {
51         this.lat = lat;
52     }
53
54     public double getLon() {
55         return lon;
56     }
57
58     public void setLon(double lon) {
59         this.lon = lon;
60     }
61
62     public String getTimezone() {
63         return timezone;
64     }
65
66     public void setTimezone(String timezone) {
67         this.timezone = timezone;
68     }
69
70     public int getTimezoneOffset() {
71         return timezoneOffset;
72     }
73
74     public void setTimezoneOffset(int timezoneOffset) {
75         this.timezoneOffset = timezoneOffset;
76     }
77
78     public Current getCurrent() {
79         return current;
80     }
81
82     public void setCurrent(Current current) {
83         this.current = current;
84     }
85
86     public List<Minutely> getMinutely() {
87         return minutely;
88     }
89
90     public void setMinutely(List<Minutely> minutely) {
91         this.minutely = minutely;
92     }
93
94     public List<Hourly> getHourly() {
95         return hourly;
96     }
97
98     public void setHourly(List<Hourly> hourly) {
99         this.hourly = hourly;
100     }
101
102     public List<Daily> getDaily() {
103         return daily;
104     }
105
106     public void setDaily(List<Daily> daily) {
107         this.daily = daily;
108     }
109 }