1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
| @Entity
@Table(name = "pogoda", schema = "climate", catalog = "")
public class PogodaEntity {
private int idPogoda;
private Date data;
private Integer tNoh;
private Integer tUtro;
private Integer tDay;
private Integer tVeher;
private Integer vlagnosty;
private Integer davlenie;
private Integer skorostyVetra;
private Integer temperaturaVoda;
private NaselennayPunktEntity naselennayPunktByIdPunkt;
private AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyNoh;
private AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyUtro;
private AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyDay;
private AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyVeher;
private VeterEntity veterByNapravlenieVetra;
public PogodaEntity(int idPogoda, Date data, Integer tNoh, Integer tUtro, Integer tDay, Integer tVeher, Integer vlagnosty, Integer davlenie, Integer skorostyVetra, Integer temperaturaVoda, NaselennayPunktEntity naselennayPunktByIdPunkt, AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyNoh, AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyUtro, AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyDay, AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyVeher, VeterEntity veterByNapravlenieVetra) {
this.idPogoda = idPogoda;
this.data = data;
this.tNoh = tNoh;
this.tUtro = tUtro;
this.tDay = tDay;
this.tVeher = tVeher;
this.vlagnosty = vlagnosty;
this.davlenie = davlenie;
this.skorostyVetra = skorostyVetra;
this.temperaturaVoda = temperaturaVoda;
this.naselennayPunktByIdPunkt = naselennayPunktByIdPunkt;
this.atmosfernaeYvleniyByIdOsadkyNoh = atmosfernaeYvleniyByIdOsadkyNoh;
this.atmosfernaeYvleniyByIdOsadkyUtro = atmosfernaeYvleniyByIdOsadkyUtro;
this.atmosfernaeYvleniyByIdOsadkyDay = atmosfernaeYvleniyByIdOsadkyDay;
this.atmosfernaeYvleniyByIdOsadkyVeher = atmosfernaeYvleniyByIdOsadkyVeher;
this.veterByNapravlenieVetra = veterByNapravlenieVetra;
}
public PogodaEntity() {
}
@Id
@Column(name = "id_pogoda", nullable = false)
public int getIdPogoda() {
return idPogoda;
}
public void setIdPogoda(int idPogoda) {
this.idPogoda = idPogoda;
}
@Basic
@Column(name = "Data_", nullable = false)
public Date getData() {
return data;
}
public void setData(Date data) {
this.data = data;
}
@Basic
@Column(name = "t_noh", nullable = true)
public Integer gettNoh() {
return tNoh;
}
public void settNoh(Integer tNoh) {
this.tNoh = tNoh;
}
@Basic
@Column(name = "t_utro", nullable = true)
public Integer gettUtro() {
return tUtro;
}
public void settUtro(Integer tUtro) {
this.tUtro = tUtro;
}
@Basic
@Column(name = "t_day", nullable = true)
public Integer gettDay() {
return tDay;
}
public void settDay(Integer tDay) {
this.tDay = tDay;
}
@Basic
@Column(name = "t_veher", nullable = true)
public Integer gettVeher() {
return tVeher;
}
public void settVeher(Integer tVeher) {
this.tVeher = tVeher;
}
@Basic
@Column(name = "Vlagnosty", nullable = true)
public Integer getVlagnosty() {
return vlagnosty;
}
public void setVlagnosty(Integer vlagnosty) {
this.vlagnosty = vlagnosty;
}
@Basic
@Column(name = "Davlenie", nullable = true)
public Integer getDavlenie() {
return davlenie;
}
public void setDavlenie(Integer davlenie) {
this.davlenie = davlenie;
}
@Basic
@Column(name = "Skorosty_vetra", nullable = true)
public Integer getSkorostyVetra() {
return skorostyVetra;
}
public void setSkorostyVetra(Integer skorostyVetra) {
this.skorostyVetra = skorostyVetra;
}
@Basic
@Column(name = "Temperatura_voda", nullable = true)
public Integer getTemperaturaVoda() {
return temperaturaVoda;
}
public void setTemperaturaVoda(Integer temperaturaVoda) {
this.temperaturaVoda = temperaturaVoda;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
PogodaEntity that = (PogodaEntity) o;
if (idPogoda != that.idPogoda) return false;
if (data != null ? !data.equals(that.data) : that.data != null) return false;
if (tNoh != null ? !tNoh.equals(that.tNoh) : that.tNoh != null) return false;
if (tUtro != null ? !tUtro.equals(that.tUtro) : that.tUtro != null) return false;
if (tDay != null ? !tDay.equals(that.tDay) : that.tDay != null) return false;
if (tVeher != null ? !tVeher.equals(that.tVeher) : that.tVeher != null) return false;
if (vlagnosty != null ? !vlagnosty.equals(that.vlagnosty) : that.vlagnosty != null) return false;
if (davlenie != null ? !davlenie.equals(that.davlenie) : that.davlenie != null) return false;
if (skorostyVetra != null ? !skorostyVetra.equals(that.skorostyVetra) : that.skorostyVetra != null)
return false;
if (temperaturaVoda != null ? !temperaturaVoda.equals(that.temperaturaVoda) : that.temperaturaVoda != null)
return false;
return true;
}
@Override
public int hashCode() {
int result = idPogoda;
result = 31 * result + (data != null ? data.hashCode() : 0);
result = 31 * result + (tNoh != null ? tNoh.hashCode() : 0);
result = 31 * result + (tUtro != null ? tUtro.hashCode() : 0);
result = 31 * result + (tDay != null ? tDay.hashCode() : 0);
result = 31 * result + (tVeher != null ? tVeher.hashCode() : 0);
result = 31 * result + (vlagnosty != null ? vlagnosty.hashCode() : 0);
result = 31 * result + (davlenie != null ? davlenie.hashCode() : 0);
result = 31 * result + (skorostyVetra != null ? skorostyVetra.hashCode() : 0);
result = 31 * result + (temperaturaVoda != null ? temperaturaVoda.hashCode() : 0);
return result;
}
@ManyToOne
@JoinColumn(name = "id_punkt", referencedColumnName = "id_punkt", nullable = false)
public NaselennayPunktEntity getNaselennayPunktByIdPunkt() {
return naselennayPunktByIdPunkt;
}
public void setNaselennayPunktByIdPunkt(NaselennayPunktEntity naselennayPunktByIdPunkt) {
this.naselennayPunktByIdPunkt = naselennayPunktByIdPunkt;
}
@ManyToOne
@JoinColumn(name = "id_osadky_noh", referencedColumnName = "id_osadky")
public AtmosfernaeYvleniyEntity getAtmosfernaeYvleniyByIdOsadkyNoh() {
return atmosfernaeYvleniyByIdOsadkyNoh;
}
public void setAtmosfernaeYvleniyByIdOsadkyNoh(AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyNoh) {
this.atmosfernaeYvleniyByIdOsadkyNoh = atmosfernaeYvleniyByIdOsadkyNoh;
}
@ManyToOne
@JoinColumn(name = "id_osadky_utro", referencedColumnName = "id_osadky")
public AtmosfernaeYvleniyEntity getAtmosfernaeYvleniyByIdOsadkyUtro() {
return atmosfernaeYvleniyByIdOsadkyUtro;
}
public void setAtmosfernaeYvleniyByIdOsadkyUtro(AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyUtro) {
this.atmosfernaeYvleniyByIdOsadkyUtro = atmosfernaeYvleniyByIdOsadkyUtro;
}
@ManyToOne
@JoinColumn(name = "id_osadky_day", referencedColumnName = "id_osadky")
public AtmosfernaeYvleniyEntity getAtmosfernaeYvleniyByIdOsadkyDay() {
return atmosfernaeYvleniyByIdOsadkyDay;
}
public void setAtmosfernaeYvleniyByIdOsadkyDay(AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyDay) {
this.atmosfernaeYvleniyByIdOsadkyDay = atmosfernaeYvleniyByIdOsadkyDay;
}
@ManyToOne
@JoinColumn(name = "id_osadky_veher", referencedColumnName = "id_osadky")
public AtmosfernaeYvleniyEntity getAtmosfernaeYvleniyByIdOsadkyVeher() {
return atmosfernaeYvleniyByIdOsadkyVeher;
}
public void setAtmosfernaeYvleniyByIdOsadkyVeher(AtmosfernaeYvleniyEntity atmosfernaeYvleniyByIdOsadkyVeher) {
this.atmosfernaeYvleniyByIdOsadkyVeher = atmosfernaeYvleniyByIdOsadkyVeher;
}
@ManyToOne
@JoinColumn(name = "Napravlenie_vetra", referencedColumnName = "id_veter")
public VeterEntity getVeterByNapravlenieVetra() {
return veterByNapravlenieVetra;
}
public void setVeterByNapravlenieVetra(VeterEntity veterByNapravlenieVetra) {
this.veterByNapravlenieVetra = veterByNapravlenieVetra;
}
public String toString(){
return "idPogoda: "+idPogoda+" naselennayPunktByIdPunkt "+naselennayPunktByIdPunkt+" Date: "+ data+ " tNoh " + tNoh
+ " tUtro " + tUtro+ " tDay " + tDay+ " tNoh " + tNoh+
"vlagnosty"+ vlagnosty+"davlenie"+ davlenie+"skorostyVetra" +skorostyVetra+
"temperaturaVoda"+temperaturaVoda+" atmosfernaeYvleniy " +atmosfernaeYvleniyByIdOsadkyNoh+
" atmosfernaeYvleniy "+ atmosfernaeYvleniyByIdOsadkyUtro +" atmosfernaeYvleniy "+atmosfernaeYvleniyByIdOsadkyDay+
" atmosfernaeYvleniy "+ atmosfernaeYvleniyByIdOsadkyVeher+" Veter " +veterByNapravlenieVetra;
}
} |