/*
 * Copyright (c) 2009, 2012, Oracle and/or its affiliates. All rights reserved.
 * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 */

package com.sun.ts.tests.jpa.core.annotations.mapkeyjoincolumn;

import javax.persistence.Entity;
import javax.persistence.Id;

@Entity
public class Semester implements java.io.Serializable {

    @Id
    int id;

    public Semester() {
    }

    public Semester(int id) {
        this.id = id;
    }

    public int getId() {
        return id;
    }

    public void setId(int semester) {
        this.id = semester;
    }

    public int hashCode() {

        return id;
    }

    public boolean equals(Object obj) {
        boolean result = false;

        if ((obj != null) && (obj instanceof Semester)) {
            Semester semester = (Semester) obj;
            result = (semester.getId() == (this.id));
        }
        return result;
    }
}
