1
2
3
4
5
6 package fr.ifremer.quadrige3.core.dao.system;
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28 import java.io.Serializable;
29 import java.sql.Timestamp;
30
31
32
33
34
35
36 public abstract class SextantLayer
37 implements Serializable, Comparable<SextantLayer>
38 {
39
40
41
42 private static final long serialVersionUID = 5342183700174823212L;
43
44
45 private String sextantLayerCd;
46
47
48
49
50
51 public String getSextantLayerCd()
52 {
53 return this.sextantLayerCd;
54 }
55
56
57
58
59
60 public void setSextantLayerCd(String sextantLayerCdIn)
61 {
62 this.sextantLayerCd = sextantLayerCdIn;
63 }
64
65 private String sextantLayerNm;
66
67
68
69
70
71 public String getSextantLayerNm()
72 {
73 return this.sextantLayerNm;
74 }
75
76
77
78
79
80 public void setSextantLayerNm(String sextantLayerNmIn)
81 {
82 this.sextantLayerNm = sextantLayerNmIn;
83 }
84
85 private String sextantLayerCopyright;
86
87
88
89
90
91 public String getSextantLayerCopyright()
92 {
93 return this.sextantLayerCopyright;
94 }
95
96
97
98
99
100 public void setSextantLayerCopyright(String sextantLayerCopyrightIn)
101 {
102 this.sextantLayerCopyright = sextantLayerCopyrightIn;
103 }
104
105 private String sextantLayerOrigin;
106
107
108
109
110
111 public String getSextantLayerOrigin()
112 {
113 return this.sextantLayerOrigin;
114 }
115
116
117
118
119
120 public void setSextantLayerOrigin(String sextantLayerOriginIn)
121 {
122 this.sextantLayerOrigin = sextantLayerOriginIn;
123 }
124
125 private String sextantLayerRef;
126
127
128
129
130
131 public String getSextantLayerRef()
132 {
133 return this.sextantLayerRef;
134 }
135
136
137
138
139
140 public void setSextantLayerRef(String sextantLayerRefIn)
141 {
142 this.sextantLayerRef = sextantLayerRefIn;
143 }
144
145 private Timestamp updateDt;
146
147
148
149
150
151 public Timestamp getUpdateDt()
152 {
153 return this.updateDt;
154 }
155
156
157
158
159
160 public void setUpdateDt(Timestamp updateDtIn)
161 {
162 this.updateDt = updateDtIn;
163 }
164
165
166
167
168
169
170 @Override
171 public boolean equals(Object object)
172 {
173 if (this == object)
174 {
175 return true;
176 }
177 if (!(object instanceof SextantLayer))
178 {
179 return false;
180 }
181 final SextantLayer that = (SextantLayer)object;
182 if (this.sextantLayerCd == null || that.getSextantLayerCd() == null || !this.sextantLayerCd.equals(that.getSextantLayerCd()))
183 {
184 return false;
185 }
186 return true;
187 }
188
189
190
191
192 @Override
193 public int hashCode()
194 {
195 int hashCode = 0;
196 hashCode = 29 * hashCode + (this.sextantLayerCd == null ? 0 : this.sextantLayerCd.hashCode());
197
198 return hashCode;
199 }
200
201
202
203
204 public static final class Factory
205 {
206
207
208
209
210 public static SextantLayer newInstance()
211 {
212 return new SextantLayerImpl();
213 }
214
215
216
217
218
219
220
221 public static SextantLayer newInstance(String sextantLayerNm)
222 {
223 final SextantLayer entity = new SextantLayerImpl();
224 entity.setSextantLayerNm(sextantLayerNm);
225 return entity;
226 }
227
228
229
230
231
232
233
234
235
236
237
238 public static SextantLayer newInstance(String sextantLayerNm, String sextantLayerCopyright, String sextantLayerOrigin, String sextantLayerRef, Timestamp updateDt)
239 {
240 final SextantLayer entity = new SextantLayerImpl();
241 entity.setSextantLayerNm(sextantLayerNm);
242 entity.setSextantLayerCopyright(sextantLayerCopyright);
243 entity.setSextantLayerOrigin(sextantLayerOrigin);
244 entity.setSextantLayerRef(sextantLayerRef);
245 entity.setUpdateDt(updateDt);
246 return entity;
247 }
248 }
249
250
251
252
253 public int compareTo(SextantLayer o)
254 {
255 int cmp = 0;
256 if (this.getSextantLayerCd() != null)
257 {
258 cmp = this.getSextantLayerCd().compareTo(o.getSextantLayerCd());
259 }
260 else
261 {
262 if (this.getSextantLayerNm() != null)
263 {
264 cmp = (cmp != 0 ? cmp : this.getSextantLayerNm().compareTo(o.getSextantLayerNm()));
265 }
266 if (this.getSextantLayerCopyright() != null)
267 {
268 cmp = (cmp != 0 ? cmp : this.getSextantLayerCopyright().compareTo(o.getSextantLayerCopyright()));
269 }
270 if (this.getSextantLayerOrigin() != null)
271 {
272 cmp = (cmp != 0 ? cmp : this.getSextantLayerOrigin().compareTo(o.getSextantLayerOrigin()));
273 }
274 if (this.getSextantLayerRef() != null)
275 {
276 cmp = (cmp != 0 ? cmp : this.getSextantLayerRef().compareTo(o.getSextantLayerRef()));
277 }
278 if (this.getUpdateDt() != null)
279 {
280 cmp = (cmp != 0 ? cmp : this.getUpdateDt().compareTo(o.getUpdateDt()));
281 }
282 }
283 return cmp;
284 }
285
286
287 }