1 package ecar.pojo;
2
3
4
5 import java.util.Date;
6
7 import javax.persistence.Column;
8 import javax.persistence.Entity;
9 import javax.persistence.FetchType;
10 import javax.persistence.GeneratedValue;
11 import javax.persistence.Id;
12 import javax.persistence.JoinColumn;
13 import javax.persistence.ManyToOne;
14 import javax.persistence.Table;
15 import javax.persistence.Temporal;
16 import javax.persistence.TemporalType;
17
18 import org.apache.commons.lang.builder.EqualsBuilder;
19 import org.apache.commons.lang.builder.HashCodeBuilder;
20 import org.apache.commons.lang.builder.ToStringBuilder;
21 import org.hibernate.annotations.GenericGenerator;
22
23
24
25
26 @Entity
27 @Table(name = "TB_ITEM_ESTRUT_USUARIO_IETTUS")
28 public class ItemEstrutUsuarioIettus implements java.io.Serializable {
29
30 private Long codIettus;
31 private String codTpPermIettus;
32 private String indLeituraIettus;
33 private String indExcluirIettus;
34 private String indEdicaoIettus;
35 private String indAtivMonitIettus;
36 private String indDesatMonitIettus;
37 private String indBloqPlanIettus;
38 private String indDesblPlanIettus;
39 private String indInfAndamentoIettus;
40 private String indEmitePosIettus;
41 private String indProxNivelIettus;
42 private Date dataInclusaoIettus;
43 private Boolean indExclusaoPosHistorico;
44 private String indLeituraParecerIettus;
45 private ItemEstruturaIett itemEstruturaIett;
46 private UsuarioUsu usuarioUsu;
47 private ItemEstruturaIett itemEstruturaIettOrigem;
48 private SisAtributoSatb sisAtributoSatb;
49 private TipoFuncAcompTpfa tipoFuncAcompTpfa;
50 private UsuarioUsu usuManutencao;
51
52 public ItemEstrutUsuarioIettus() {
53 }
54
55
56 public ItemEstrutUsuarioIettus(ItemEstruturaIett itemEstruturaIett, ItemEstruturaIett itemEstruturaIettOrigem, UsuarioUsu usuarioUsu, String codTpPermIettus, SisAtributoSatb sisAtributoSatb, TipoFuncAcompTpfa tipoFuncAcompTpfa, String indLeitura, String indEdicao, String indExcluir, String indAtivMonit, String indDesatMonit, String indBloqPlan, String indDesblPlan, String indInfAndamento, String indEmitePos, String indProxNiv, Date dataInclusao, String indLeituraParecer) {
57 this.itemEstruturaIett = itemEstruturaIett;
58 this.itemEstruturaIettOrigem = itemEstruturaIettOrigem;
59 this.usuarioUsu = usuarioUsu;
60 this.codTpPermIettus = codTpPermIettus;
61 this.sisAtributoSatb = sisAtributoSatb;
62 this.tipoFuncAcompTpfa = tipoFuncAcompTpfa;
63 this.indLeituraIettus = indLeitura;
64 this.indEdicaoIettus = indEdicao;
65 this.indExcluirIettus = indExcluir;
66 this.indAtivMonitIettus = indAtivMonit;
67 this.indDesatMonitIettus = indDesatMonit;
68 this.indBloqPlanIettus = indBloqPlan;
69 this.indDesblPlanIettus = indDesblPlan;
70 this.indInfAndamentoIettus = indInfAndamento;
71 this.indEmitePosIettus = indEmitePos;
72 this.indProxNivelIettus = indProxNiv;
73 this.dataInclusaoIettus = dataInclusao;
74 this.indLeituraParecerIettus = indLeituraParecer;
75 }
76
77 @GenericGenerator(name = "generator", strategy = "increment")
78 @Id
79 @GeneratedValue(generator = "generator")
80 @Column(name = "COD_IETTUS", nullable = false)
81 public Long getCodIettus() {
82 return this.codIettus;
83 }
84
85 public void setCodIettus(Long codIettus) {
86 this.codIettus = codIettus;
87 }
88
89 @Column(name = "COD_TP_PERM_IETTUS", length = 1)
90 public String getCodTpPermIettus() {
91 return this.codTpPermIettus;
92 }
93
94 public void setCodTpPermIettus(String codTpPermIettus) {
95 this.codTpPermIettus = codTpPermIettus;
96 }
97
98 @Column(name = "IND_LEITURA_IETTUS", length = 1)
99 public String getIndLeituraIettus() {
100 return this.indLeituraIettus;
101 }
102
103 public void setIndLeituraIettus(String indLeituraIettus) {
104 this.indLeituraIettus = indLeituraIettus;
105 }
106
107 @Column(name = "IND_EXCLUIR_IETTUS", length = 1)
108 public String getIndExcluirIettus() {
109 return this.indExcluirIettus;
110 }
111
112 public void setIndExcluirIettus(String indExcluirIettus) {
113 this.indExcluirIettus = indExcluirIettus;
114 }
115
116 @Column(name = "IND_EDICAO_IETTUS", length = 1)
117 public String getIndEdicaoIettus() {
118 return this.indEdicaoIettus;
119 }
120
121 public void setIndEdicaoIettus(String indEdicaoIettus) {
122 this.indEdicaoIettus = indEdicaoIettus;
123 }
124
125 @Column(name = "IND_ATIV_MONIT_IETTUS", length = 1)
126 public String getIndAtivMonitIettus() {
127 return this.indAtivMonitIettus;
128 }
129
130 public void setIndAtivMonitIettus(String indAtivMonitIettus) {
131 this.indAtivMonitIettus = indAtivMonitIettus;
132 }
133
134 @Column(name = "IND_DESAT_MONIT_IETTUS", length = 1)
135 public String getIndDesatMonitIettus() {
136 return this.indDesatMonitIettus;
137 }
138
139 public void setIndDesatMonitIettus(String indDesatMonitIettus) {
140 this.indDesatMonitIettus = indDesatMonitIettus;
141 }
142
143 @Column(name = "IND_BLOQ_PLAN_IETTUS", length = 1)
144 public String getIndBloqPlanIettus() {
145 return this.indBloqPlanIettus;
146 }
147
148 public void setIndBloqPlanIettus(String indBloqPlanIettus) {
149 this.indBloqPlanIettus = indBloqPlanIettus;
150 }
151
152 @Column(name = "IND_DESBL_PLAN_IETTUS", length = 1)
153 public String getIndDesblPlanIettus() {
154 return this.indDesblPlanIettus;
155 }
156
157 public void setIndDesblPlanIettus(String indDesblPlanIettus) {
158 this.indDesblPlanIettus = indDesblPlanIettus;
159 }
160
161 @Column(name = "IND_INF_ANDAMENTO_IETTUS", length = 1)
162 public String getIndInfAndamentoIettus() {
163 return this.indInfAndamentoIettus;
164 }
165
166 public void setIndInfAndamentoIettus(String indInfAndamentoIettus) {
167 this.indInfAndamentoIettus = indInfAndamentoIettus;
168 }
169
170 @Column(name = "IND_EMITE_POS_IETTUS", length = 1)
171 public String getIndEmitePosIettus() {
172 return this.indEmitePosIettus;
173 }
174
175 public void setIndEmitePosIettus(String indEmitePosIettus) {
176 this.indEmitePosIettus = indEmitePosIettus;
177 }
178
179 @Column(name = "IND_PROX_NIVEL_IETTUS", length = 1)
180 public String getIndProxNivelIettus() {
181 return this.indProxNivelIettus;
182 }
183
184 public void setIndProxNivelIettus(String indProxNivelIettus) {
185 this.indProxNivelIettus = indProxNivelIettus;
186 }
187
188 @Temporal(TemporalType.TIMESTAMP)
189 @Column(name = "DATA_INCLUSAO_IETTUS", length = 7)
190 public Date getDataInclusaoIettus() {
191 return this.dataInclusaoIettus;
192 }
193
194 public void setDataInclusaoIettus(Date dataInclusaoIettus) {
195 this.dataInclusaoIettus = dataInclusaoIettus;
196 }
197
198 @Column(name = "IND_EXCLUSAO_POS_HISTORICO")
199 public Boolean getIndExclusaoPosHistorico() {
200 return this.indExclusaoPosHistorico;
201 }
202
203 public void setIndExclusaoPosHistorico(Boolean indExclusaoPosHistorico) {
204 this.indExclusaoPosHistorico = indExclusaoPosHistorico;
205 }
206
207 @Column(name = "IND_LEITURA_PARECER_IETTUS", length = 1)
208 public String getIndLeituraParecerIettus() {
209 return this.indLeituraParecerIettus;
210 }
211
212 public void setIndLeituraParecerIettus(String indLeituraParecerIettus) {
213 this.indLeituraParecerIettus = indLeituraParecerIettus;
214 }
215
216 @ManyToOne(fetch = FetchType.LAZY)
217 @JoinColumn(name = "COD_IETT")
218 public ItemEstruturaIett getItemEstruturaIett() {
219 return this.itemEstruturaIett;
220 }
221
222 public void setItemEstruturaIett(ItemEstruturaIett itemEstruturaIett) {
223 this.itemEstruturaIett = itemEstruturaIett;
224 }
225
226 @ManyToOne(fetch = FetchType.LAZY)
227 @JoinColumn(name = "COD_USU")
228 public UsuarioUsu getUsuarioUsu() {
229 return this.usuarioUsu;
230 }
231
232 public void setUsuarioUsu(UsuarioUsu usuarioUsu) {
233 this.usuarioUsu = usuarioUsu;
234 }
235
236 @ManyToOne(fetch = FetchType.LAZY)
237 @JoinColumn(name = "COD_IETT_ORIG")
238 public ItemEstruturaIett getItemEstruturaIettOrigem() {
239 return this.itemEstruturaIettOrigem;
240 }
241
242 public void setItemEstruturaIettOrigem(ItemEstruturaIett itemEstruturaIettOrigem) {
243 this.itemEstruturaIettOrigem = itemEstruturaIettOrigem;
244 }
245
246 @ManyToOne(fetch = FetchType.LAZY)
247 @JoinColumn(name = "COD_ATB")
248 public SisAtributoSatb getSisAtributoSatb() {
249 return this.sisAtributoSatb;
250 }
251
252 public void setSisAtributoSatb(SisAtributoSatb sisAtributoSatb) {
253 this.sisAtributoSatb = sisAtributoSatb;
254 }
255
256 @ManyToOne(fetch = FetchType.LAZY)
257 @JoinColumn(name = "COD_TPFA")
258 public TipoFuncAcompTpfa getTipoFuncAcompTpfa() {
259 return this.tipoFuncAcompTpfa;
260 }
261
262 public void setTipoFuncAcompTpfa(TipoFuncAcompTpfa tipoFuncAcompTpfa) {
263 this.tipoFuncAcompTpfa = tipoFuncAcompTpfa;
264 }
265
266 @ManyToOne(fetch = FetchType.LAZY)
267 @JoinColumn(name = "COD_USU_MANUTENCAO")
268 public UsuarioUsu getUsuManutencao() {
269 return this.usuManutencao;
270 }
271
272 public void setUsuManutencao(UsuarioUsu usuManutencao) {
273 this.usuManutencao = usuManutencao;
274 }
275
276
277
278
279
280
281
282
283
284 public Object clone() {
285
286 try {
287 ItemEstrutUsuarioIettus clone = (ItemEstrutUsuarioIettus) super.clone();
288
289 clone.setSisAtributoSatb(this.getSisAtributoSatb());
290 clone.setDataInclusaoIettus(this.getDataInclusaoIettus());
291 clone.setItemEstruturaIett(this.getItemEstruturaIett());
292 clone.setItemEstruturaIettOrigem(this.getItemEstruturaIettOrigem());
293 clone.setTipoFuncAcompTpfa(this.getTipoFuncAcompTpfa());
294 clone.setUsuarioUsu(this.getUsuarioUsu());
295 clone.setUsuManutencao(this.getUsuManutencao());
296
297 return clone;
298
299 } catch (CloneNotSupportedException e) {
300 return null;
301 }
302 }
303
304 public String toString() {
305 return new ToStringBuilder(this).append("codIettus", getCodIettus()).toString();
306 }
307
308 public boolean equals(Object other) {
309 if ((this == other))
310 return true;
311 if (!(other instanceof ItemEstrutUsuarioIettus))
312 return false;
313 ItemEstrutUsuarioIettus castOther = (ItemEstrutUsuarioIettus) other;
314
315
316
317
318
319
320
321
322
323
324 return new EqualsBuilder().append(this.getItemEstruturaIett(), castOther.getItemEstruturaIett()).append(this.getItemEstruturaIettOrigem(), castOther.getItemEstruturaIettOrigem()).append(this.getTipoFuncAcompTpfa(), castOther.getTipoFuncAcompTpfa()).append(this.getCodTpPermIettus(), castOther.getTipoFuncAcompTpfa()).append(this.getUsuarioUsu(), castOther.getUsuarioUsu()).append(this.getSisAtributoSatb(), castOther.getSisAtributoSatb()).isEquals();
325 }
326
327 public int hashCode() {
328 return new HashCodeBuilder().append(getCodIettus()).toHashCode();
329 }
330
331 }