Mercurial > dive4elements > river
comparison flys-backend/src/main/java/de/intevation/seddb/model/MessunguferbezugId.java @ 3689:c938e568c4a2 2.9
merged flys-backend/2.9
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Fri, 28 Sep 2012 12:14:44 +0200 |
parents | 2ae732e2c65c |
children | 18619c1e7c2a |
comparison
equal
deleted
inserted
replaced
3651:06a65baae494 | 3689:c938e568c4a2 |
---|---|
1 package de.intevation.seddb.model; | |
2 // Generated 14.06.2012 11:30:57 by Hibernate Tools 3.4.0.CR1 | |
3 | |
4 | |
5 import java.math.BigDecimal; | |
6 import javax.persistence.Column; | |
7 import javax.persistence.Embeddable; | |
8 | |
9 /** | |
10 * MessunguferbezugId generated by hbm2java | |
11 */ | |
12 @Embeddable | |
13 public class MessunguferbezugId implements java.io.Serializable { | |
14 | |
15 | |
16 private long messungid; | |
17 private boolean uferistlinks; | |
18 private BigDecimal hmabst; | |
19 | |
20 public MessunguferbezugId() { | |
21 } | |
22 | |
23 public MessunguferbezugId(long messungid, boolean uferistlinks) { | |
24 this.messungid = messungid; | |
25 this.uferistlinks = uferistlinks; | |
26 } | |
27 public MessunguferbezugId(long messungid, boolean uferistlinks, BigDecimal hmabst) { | |
28 this.messungid = messungid; | |
29 this.uferistlinks = uferistlinks; | |
30 this.hmabst = hmabst; | |
31 } | |
32 | |
33 | |
34 | |
35 @Column(name="MESSUNGID", nullable=false, precision=11, scale=0) | |
36 public long getMessungid() { | |
37 return this.messungid; | |
38 } | |
39 | |
40 public void setMessungid(long messungid) { | |
41 this.messungid = messungid; | |
42 } | |
43 | |
44 | |
45 @Column(name="UFERISTLINKS", nullable=false, precision=1, scale=0) | |
46 public boolean isUferistlinks() { | |
47 return this.uferistlinks; | |
48 } | |
49 | |
50 public void setUferistlinks(boolean uferistlinks) { | |
51 this.uferistlinks = uferistlinks; | |
52 } | |
53 | |
54 | |
55 @Column(name="HMABST", precision=8, scale=3) | |
56 public BigDecimal getHmabst() { | |
57 return this.hmabst; | |
58 } | |
59 | |
60 public void setHmabst(BigDecimal hmabst) { | |
61 this.hmabst = hmabst; | |
62 } | |
63 | |
64 | |
65 public boolean equals(Object other) { | |
66 if ( (this == other ) ) return true; | |
67 if ( (other == null ) ) return false; | |
68 if ( !(other instanceof MessunguferbezugId) ) return false; | |
69 MessunguferbezugId castOther = ( MessunguferbezugId ) other; | |
70 | |
71 return (this.getMessungid()==castOther.getMessungid()) | |
72 && (this.isUferistlinks()==castOther.isUferistlinks()) | |
73 && ( (this.getHmabst()==castOther.getHmabst()) || ( this.getHmabst()!=null && castOther.getHmabst()!=null && this.getHmabst().equals(castOther.getHmabst()) ) ); | |
74 } | |
75 | |
76 public int hashCode() { | |
77 int result = 17; | |
78 | |
79 result = 37 * result + (int) this.getMessungid(); | |
80 result = 37 * result + (this.isUferistlinks()?1:0); | |
81 result = 37 * result + ( getHmabst() == null ? 0 : this.getHmabst().hashCode() ); | |
82 return result; | |
83 } | |
84 } |