Subversion Repositories WebE

Rev

Rev 21 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 21 Rev 33
Line 24... Line 24...
24
                "term_from", "term_to", "type" }))
24
                "term_from", "term_to", "type" }))
25
public class Relationship implements java.io.Serializable {
25
public class Relationship implements java.io.Serializable {
26
26
27
        private int objectId;
27
        private int objectId;
28
        private Term termByTermTo;
28
        private Term termByTermTo;
29
        private Object object;
29
        private ObjectEntity object;
30
        private RelationshipType relationshipType;
30
        private RelationshipType relationshipType;
31
        private Term termByTermFrom;
31
        private Term termByTermFrom;
32
32
33
        public Relationship() {
33
        public Relationship() {
34
        }
34
        }
35
35
36
        public Relationship(Term termByTermTo, Object object,
36
        public Relationship(Term termByTermTo, ObjectEntity object,
37
                        RelationshipType relationshipType, Term termByTermFrom) {
37
                        RelationshipType relationshipType, Term termByTermFrom) {
38
                this.termByTermTo = termByTermTo;
38
                this.termByTermTo = termByTermTo;
39
                this.object = object;
39
                this.object = object;
40
                this.relationshipType = relationshipType;
40
                this.relationshipType = relationshipType;
41
                this.termByTermFrom = termByTermFrom;
41
                this.termByTermFrom = termByTermFrom;
Line 63... Line 63...
63
                this.termByTermTo = termByTermTo;
63
                this.termByTermTo = termByTermTo;
64
        }
64
        }
65
65
66
        @OneToOne(fetch = FetchType.LAZY)
66
        @OneToOne(fetch = FetchType.LAZY)
67
        @PrimaryKeyJoinColumn
67
        @PrimaryKeyJoinColumn
68
        public Object getObject() {
68
        public ObjectEntity getObject() {
69
                return this.object;
69
                return this.object;
70
        }
70
        }
71
71
72
        public void setObject(Object object) {
72
        public void setObject(ObjectEntity object) {
73
                this.object = object;
73
                this.object = object;
74
        }
74
        }
75
75
76
        @ManyToOne(fetch = FetchType.LAZY)
76
        @ManyToOne(fetch = FetchType.LAZY)
77
        @JoinColumn(name = "type", nullable = false)
77
        @JoinColumn(name = "type", nullable = false)