//
// This file was generated by the Jeddict
//
package org.ohdsi.webapi.cohortanalysis;

import java.io.Serializable;



public class CohortAnalysisGenerationInfoPK implements Serializable {

    private Integer sourceId;

    private Integer cohortDefinition;

    public CohortAnalysisGenerationInfoPK(){
    }

    public CohortAnalysisGenerationInfoPK(Integer sourceId,Integer cohortDefinition){
        this.sourceId=sourceId;
        this.cohortDefinition=cohortDefinition;
    }


   public Integer getSourceId() {
        return this.sourceId;
    }

    public void setSourceId (Integer sourceId) {
        this.sourceId = sourceId;
    }

   public Integer getCohortDefinition() {
        return this.cohortDefinition;
    }

    public void setCohortDefinition (Integer cohortDefinition) {
        this.cohortDefinition = cohortDefinition;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {return false;}
        if (!java.util.Objects.equals(getClass(), obj.getClass())) {return false;}
        final CohortAnalysisGenerationInfoPK other = (CohortAnalysisGenerationInfoPK) obj;
        if (!java.util.Objects.equals(this.getSourceId(), other.getSourceId())) {        return false;        }
        if (!java.util.Objects.equals(this.getCohortDefinition(), other.getCohortDefinition())) {        return false;        }
        return true;
    }

    @Override
    public int hashCode() {
        int hash = 7;
        hash = 59 * hash + (this.getSourceId() != null ? this.getSourceId().hashCode() : 0);
        hash = 59 * hash + (this.getCohortDefinition() != null ? this.getCohortDefinition().hashCode() : 0);
        return hash;
    }

    @Override
    public String toString() {
        return "CohortAnalysisGenerationInfoPK{" + " sourceId=" + sourceId + ", cohortDefinition=" + cohortDefinition + '}';
    }

}
