Mercurial > dive4elements > river
comparison flys-backend/src/main/java/de/intevation/flys/model/Annotation.java @ 758:bf16268629d9
Added 'Kanten' model
flys-backend/trunk@2106 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Tue, 14 Jun 2011 12:34:08 +0000 |
parents | 003ac16812dd |
children | 8076f6a689d0 |
comparison
equal
deleted
inserted
replaced
757:c19d4c643526 | 758:bf16268629d9 |
---|---|
19 { | 19 { |
20 private Integer id; | 20 private Integer id; |
21 private Range range; | 21 private Range range; |
22 private Attribute attribute; | 22 private Attribute attribute; |
23 private Position position; | 23 private Position position; |
24 private Edge edge; | |
24 | 25 |
25 public Annotation() { | 26 public Annotation() { |
26 } | 27 } |
27 | 28 |
28 public Annotation(Range range, Attribute attribute, Position position) { | 29 public Annotation(Range range, Attribute attribute, Position position) { |
30 this(range, attribute, position, null); | |
31 } | |
32 | |
33 public Annotation( | |
34 Range range, | |
35 Attribute attribute, | |
36 Position position, | |
37 Edge edge | |
38 ) { | |
29 this.range = range; | 39 this.range = range; |
30 this.attribute = attribute; | 40 this.attribute = attribute; |
31 this.position = position; | 41 this.position = position; |
42 this.edge = edge; | |
32 } | 43 } |
33 | 44 |
34 @Id | 45 @Id |
35 @SequenceGenerator( | 46 @SequenceGenerator( |
36 name = "SEQUENCE_ANNOTATIONS_ID_SEQ", | 47 name = "SEQUENCE_ANNOTATIONS_ID_SEQ", |
75 } | 86 } |
76 | 87 |
77 public void setPosition(Position position) { | 88 public void setPosition(Position position) { |
78 this.position = position; | 89 this.position = position; |
79 } | 90 } |
91 | |
92 @OneToOne | |
93 @JoinColumn(name = "edge_id") | |
94 public Edge getEdge() { | |
95 return edge; | |
96 } | |
97 | |
98 public void setEdge(Edge edge) { | |
99 this.edge = edge; | |
100 } | |
80 } | 101 } |
81 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : | 102 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : |