package com.publiccms.entities.cms;
// Generated 2026-1-4 13:40:55 by Hibernate Tools 5.6.15.Final


import javax.persistence.Column;
import javax.persistence.Embeddable;

import com.publiccms.common.generator.annotation.GeneratorColumn;

/**
 * CmsCategoryLangId generated by hbm2java
 */
@Embeddable
public class CmsCategoryLangId  implements java.io.Serializable {


     private static final long serialVersionUID = 1L;
     @GeneratorColumn(title = "分类")
     private int categoryId;
     @GeneratorColumn(title = "语言")
     private String lang;

    public CmsCategoryLangId() {
    }

    public CmsCategoryLangId(int categoryId, String lang) {
       this.categoryId = categoryId;
       this.lang = lang;
    }
   


    @Column(name="category_id", nullable=false)
    public int getCategoryId() {
        return this.categoryId;
    }
    
    public void setCategoryId(int categoryId) {
        this.categoryId = categoryId;
    }


    @Column(name="lang", nullable=false, length=20)
    public String getLang() {
        return this.lang;
    }
    
    public void setLang(String lang) {
        this.lang = lang;
    }


   public boolean equals(Object other) {
         if ( (this == other ) ) return true;
		 if ( (other == null ) ) return false;
		 if ( !(other instanceof CmsCategoryLangId) ) return false;
		 CmsCategoryLangId castOther = ( CmsCategoryLangId ) other; 
         
		 return (this.getCategoryId()==castOther.getCategoryId())
 && ( (this.getLang()==castOther.getLang()) || ( this.getLang()!=null && castOther.getLang()!=null && this.getLang().equals(castOther.getLang()) ) );
   }
   
   public int hashCode() {
         int result = 17;
         
         result = 37 * result + this.getCategoryId();
         result = 37 * result + ( getLang() == null ? 0 : this.getLang().hashCode() );
         return result;
   }   


}


