package es.uv.saic.domain;

import java.io.Serializable;

import jakarta.persistence.Column;

public class InformeProcesPK implements Serializable {
	private static final long serialVersionUID = 1L;

	@Column(name="id_informe")
	private Integer idInforme;
	
	@Column(name="nom_proces")
	private String nomProces;
	
	public InformeProcesPK() {}
	
	public InformeProcesPK(Integer idInforme, String nomProces) {
		this.idInforme = idInforme;
		this.nomProces = nomProces;
	}

	public Integer getIdInforme() {
		return idInforme;
	}

	public void setIdInforme(Integer idInforme) {
		this.idInforme = idInforme;
	}

	public String getNomProces() {
		return nomProces;
	}

	public void setNomProces(String nomProces) {
		this.nomProces = nomProces;
	}

	public boolean equals(Object other) {
		if (this == other) {
			return true;
		}
		if (!(other instanceof InformeProcesPK)) {
			return false;
		}
		InformeProcesPK castOther = (InformeProcesPK)other;
		return 
			this.idInforme.equals(castOther.idInforme)
			&& this.nomProces.equals(castOther.nomProces);
	}

	public int hashCode() {
		final int prime = 31;
		int hash = 17;
		hash = hash * prime + this.idInforme.hashCode();
		hash = hash * prime + this.nomProces.hashCode();
		
		return hash;
	}
}
