/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.jpa.demo;

import java.io.Serializable;
import javax.persistence.Embeddable;

/**
 *
 * @author Administrator
 */
@Embeddable
public class StudentID implements Serializable {

    private static final long serialVersionUID = 1L;
    private int gradeno;

    public int getGradeno() {
        return gradeno;
    }

    public void setGradeno(int gradeno) {
        this.gradeno = gradeno;
    }

    public int getClassno() {
        return classno;
    }

    public void setClassno(int classno) {
        this.classno = classno;
    }
    private int classno;

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final StudentID other = (StudentID) obj;
        if (this.gradeno != other.gradeno) {
            return false;
        }
        if (this.classno != other.classno) {
            return false;
        }
        return true;
    }

    @Override
    public int hashCode() {
        int hash = 1;
       
        return hash;
    }
}
