3
import java.io.Serializable;
4
import javax.persistence.*;
7
* The primary key class for the teaches database table.
11
public class TeachPK implements Serializable {
12
//default serial version id, required for serializable classes.
13
private static final long serialVersionUID = 1L;
20
@Column(insertable=false, updatable=false, unique=true, nullable=false)
21
public Long getCourse() {
24
public void setCourse(Long course) {
28
@Column(insertable=false, updatable=false, unique=true, nullable=false)
29
public Long getStaff() {
32
public void setStaff(Long staff) {
36
public boolean equals(Object other) {
40
if (!(other instanceof TeachPK)) {
43
TeachPK castOther = (TeachPK)other;
45
this.course.equals(castOther.course)
46
&& this.staff.equals(castOther.staff);
49
public int hashCode() {
52
hash = hash * prime + this.course.hashCode();
53
hash = hash * prime + this.staff.hashCode();
b'\\ No newline at end of file'