/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package TestRest;

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

/**
 *
 * @author aparnab
 */
@Embeddable
public class AssocaroPK implements Serializable {
    @Basic(optional = false)
    @Column(name = "ORID")
    private long orid;
    @Basic(optional = false)
    @Column(name = "ARID")
    private long arid;

    public AssocaroPK() {
    }

    public AssocaroPK(long orid, long arid) {
        this.orid = orid;
        this.arid = arid;
    }

    public long getOrid() {
        return orid;
    }

    public void setOrid(long orid) {
        this.orid = orid;
    }

    public long getArid() {
        return arid;
    }

    public void setArid(long arid) {
        this.arid = arid;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (int) orid;
        hash += (int) arid;
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof AssocaroPK)) {
            return false;
        }
        AssocaroPK other = (AssocaroPK) object;
        if (this.orid != other.orid) {
            return false;
        }
        if (this.arid != other.arid) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "TestRest.AssocaroPK[orid=" + orid + ", arid=" + arid + "]";
    }

}
