/magstudentportal/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/magstudentportal/trunk

« back to all changes in this revision

Viewing changes to src/main/java/DB/StudentAttendance.java

  • Committer: Gustav Hartvigsson
  • Date: 2017-08-28 14:00:50 UTC
  • mfrom: (15.1.3 magstudentportal-more-db)
  • Revision ID: gustav.hartvigsson@gmail.com-20170828140050-zu6nqc1vlp9wnwh8
* derp?

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
package DB;
 
2
 
 
3
import java.io.Serializable;
 
4
import javax.persistence.*;
 
5
 
 
6
 
 
7
/**
 
8
 * The persistent class for the student_attendance database table.
 
9
 * 
 
10
 */
 
11
@Entity
 
12
@Table(name="student_attendance")
 
13
@NamedQuery(name="StudentAttendance.findAll", query="SELECT s FROM StudentAttendance s")
 
14
public class StudentAttendance implements Serializable {
 
15
        private static final long serialVersionUID = 1L;
 
16
        private StudentAttendancePK id;
 
17
        private Integer lateTime;
 
18
        private Lecture lecture;
 
19
        private Student studentBean;
 
20
 
 
21
        public StudentAttendance() {
 
22
        }
 
23
 
 
24
 
 
25
        @EmbeddedId
 
26
        public StudentAttendancePK getId() {
 
27
                return this.id;
 
28
        }
 
29
 
 
30
        public void setId(StudentAttendancePK id) {
 
31
                this.id = id;
 
32
        }
 
33
 
 
34
 
 
35
        @Column(name="late_time")
 
36
        public Integer getLateTime() {
 
37
                return this.lateTime;
 
38
        }
 
39
 
 
40
        public void setLateTime(Integer lateTime) {
 
41
                this.lateTime = lateTime;
 
42
        }
 
43
 
 
44
 
 
45
        //bi-directional many-to-one association to Lecture
 
46
        @ManyToOne
 
47
        @JoinColumns({
 
48
                @JoinColumn(name="lecture_course", referencedColumnName="course", nullable=false, insertable=false, updatable=false),
 
49
                @JoinColumn(name="lecture_end_time", referencedColumnName="end_time", nullable=false, insertable=false, updatable=false),
 
50
                @JoinColumn(name="lecture_start_time", referencedColumnName="start_time", nullable=false, insertable=false, updatable=false)
 
51
                })
 
52
        public Lecture getLecture() {
 
53
                return this.lecture;
 
54
        }
 
55
 
 
56
        public void setLecture(Lecture lecture) {
 
57
                this.lecture = lecture;
 
58
        }
 
59
 
 
60
 
 
61
        //bi-directional many-to-one association to Student
 
62
        @ManyToOne
 
63
        @JoinColumn(name="student", nullable=false, insertable=false, updatable=false)
 
64
        public Student getStudentBean() {
 
65
                return this.studentBean;
 
66
        }
 
67
 
 
68
        public void setStudentBean(Student studentBean) {
 
69
                this.studentBean = studentBean;
 
70
        }
 
71
 
 
72
}
 
 
b'\\ No newline at end of file'