/*
 * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
 * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
 */
package com.qsoft.rs.sincoar.model;

import java.io.Serializable;
import java.util.Collection;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlTransient;

/**
 *
 * @author developer2
 */
@Entity
@Table(name="COMACO.TGENELANGUAGE")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "Tgenelanguage.findAll", query = "SELECT t FROM Tgenelanguage t"),
    @NamedQuery(name = "Tgenelanguage.findByLanguagecode", query = "SELECT t FROM Tgenelanguage t WHERE t.languagecode = :languagecode"),
    @NamedQuery(name = "Tgenelanguage.findByDescription", query = "SELECT t FROM Tgenelanguage t WHERE t.description = :description")})
public class Tgenelanguage implements Serializable {

    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "LANGUAGECODE")
    private String languagecode;
    @Basic(optional = false)
    @Column(name = "DESCRIPTION")
    private String description;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgeneresults> tgeneresultsCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenemenuleveldesc> tgenemenuleveldescCollection;
    @OneToMany(mappedBy = "languagecode")
    private Collection<Tsafeuserdetail> tsafeuserdetailCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgeneinstallmenttypedesc> tgeneinstallmenttypedescCollection;
    @OneToMany(mappedBy = "languagecode")
    private Collection<Tcustpersondetail> tcustpersondetailCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenemenusubleveldesc> tgenemenusubleveldescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgeneconceptdesc> tgeneconceptdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenecurrencydesc> tgenecurrencydescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenecountrydesc> tgenecountrydescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgeneproductdesc> tgeneproductdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenemessagedesc> tgenemessagedescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenecatalogdesc> tgenecatalogdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenemenudesc> tgenemenudescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenemessagetemplatesdesc> tgenemessagetemplatesdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenechannelsdesc> tgenechannelsdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenesubproductdesc> tgenesubproductdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenecitydesc> tgenecitydescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenecredittypedesc> tgenecredittypedescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenetransactiondesc> tgenetransactiondescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenefrequencydesc> tgenefrequencydescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tegenecantondesc> tegenecantondescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenemoduledesc> tgenemoduledescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenecatalogdetaildesc> tgenecatalogdetaildescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenetransactionglosary> tgenetransactionglosaryCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenebalancetypedesc> tgenebalancetypedescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenebalancegroupdesc> tgenebalancegroupdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgeneprovincedesc> tgeneprovincedescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgeneprocessdesc> tgeneprocessdescCollection;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "tgenelanguage")
    private Collection<Tgenelabel> tgenelabelCollection;

    public Tgenelanguage() {
    }

    public Tgenelanguage(String languagecode) {
        this.languagecode = languagecode;
    }

    public Tgenelanguage(String languagecode, String description) {
        this.languagecode = languagecode;
        this.description = description;
    }

    public String getLanguagecode() {
        return languagecode;
    }

    public void setLanguagecode(String languagecode) {
        this.languagecode = languagecode;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    @XmlTransient
    public Collection<Tgeneresults> getTgeneresultsCollection() {
        return tgeneresultsCollection;
    }

    public void setTgeneresultsCollection(Collection<Tgeneresults> tgeneresultsCollection) {
        this.tgeneresultsCollection = tgeneresultsCollection;
    }

    @XmlTransient
    public Collection<Tgenemenuleveldesc> getTgenemenuleveldescCollection() {
        return tgenemenuleveldescCollection;
    }

    public void setTgenemenuleveldescCollection(Collection<Tgenemenuleveldesc> tgenemenuleveldescCollection) {
        this.tgenemenuleveldescCollection = tgenemenuleveldescCollection;
    }

    @XmlTransient
    public Collection<Tsafeuserdetail> getTsafeuserdetailCollection() {
        return tsafeuserdetailCollection;
    }

    public void setTsafeuserdetailCollection(Collection<Tsafeuserdetail> tsafeuserdetailCollection) {
        this.tsafeuserdetailCollection = tsafeuserdetailCollection;
    }

    @XmlTransient
    public Collection<Tgeneinstallmenttypedesc> getTgeneinstallmenttypedescCollection() {
        return tgeneinstallmenttypedescCollection;
    }

    public void setTgeneinstallmenttypedescCollection(Collection<Tgeneinstallmenttypedesc> tgeneinstallmenttypedescCollection) {
        this.tgeneinstallmenttypedescCollection = tgeneinstallmenttypedescCollection;
    }

    @XmlTransient
    public Collection<Tcustpersondetail> getTcustpersondetailCollection() {
        return tcustpersondetailCollection;
    }

    public void setTcustpersondetailCollection(Collection<Tcustpersondetail> tcustpersondetailCollection) {
        this.tcustpersondetailCollection = tcustpersondetailCollection;
    }

    @XmlTransient
    public Collection<Tgenemenusubleveldesc> getTgenemenusubleveldescCollection() {
        return tgenemenusubleveldescCollection;
    }

    public void setTgenemenusubleveldescCollection(Collection<Tgenemenusubleveldesc> tgenemenusubleveldescCollection) {
        this.tgenemenusubleveldescCollection = tgenemenusubleveldescCollection;
    }

    @XmlTransient
    public Collection<Tgeneconceptdesc> getTgeneconceptdescCollection() {
        return tgeneconceptdescCollection;
    }

    public void setTgeneconceptdescCollection(Collection<Tgeneconceptdesc> tgeneconceptdescCollection) {
        this.tgeneconceptdescCollection = tgeneconceptdescCollection;
    }

    @XmlTransient
    public Collection<Tgenecurrencydesc> getTgenecurrencydescCollection() {
        return tgenecurrencydescCollection;
    }

    public void setTgenecurrencydescCollection(Collection<Tgenecurrencydesc> tgenecurrencydescCollection) {
        this.tgenecurrencydescCollection = tgenecurrencydescCollection;
    }

    @XmlTransient
    public Collection<Tgenecountrydesc> getTgenecountrydescCollection() {
        return tgenecountrydescCollection;
    }

    public void setTgenecountrydescCollection(Collection<Tgenecountrydesc> tgenecountrydescCollection) {
        this.tgenecountrydescCollection = tgenecountrydescCollection;
    }

    @XmlTransient
    public Collection<Tgeneproductdesc> getTgeneproductdescCollection() {
        return tgeneproductdescCollection;
    }

    public void setTgeneproductdescCollection(Collection<Tgeneproductdesc> tgeneproductdescCollection) {
        this.tgeneproductdescCollection = tgeneproductdescCollection;
    }

    @XmlTransient
    public Collection<Tgenemessagedesc> getTgenemessagedescCollection() {
        return tgenemessagedescCollection;
    }

    public void setTgenemessagedescCollection(Collection<Tgenemessagedesc> tgenemessagedescCollection) {
        this.tgenemessagedescCollection = tgenemessagedescCollection;
    }

    @XmlTransient
    public Collection<Tgenecatalogdesc> getTgenecatalogdescCollection() {
        return tgenecatalogdescCollection;
    }

    public void setTgenecatalogdescCollection(Collection<Tgenecatalogdesc> tgenecatalogdescCollection) {
        this.tgenecatalogdescCollection = tgenecatalogdescCollection;
    }

    @XmlTransient
    public Collection<Tgenemenudesc> getTgenemenudescCollection() {
        return tgenemenudescCollection;
    }

    public void setTgenemenudescCollection(Collection<Tgenemenudesc> tgenemenudescCollection) {
        this.tgenemenudescCollection = tgenemenudescCollection;
    }

    @XmlTransient
    public Collection<Tgenemessagetemplatesdesc> getTgenemessagetemplatesdescCollection() {
        return tgenemessagetemplatesdescCollection;
    }

    public void setTgenemessagetemplatesdescCollection(Collection<Tgenemessagetemplatesdesc> tgenemessagetemplatesdescCollection) {
        this.tgenemessagetemplatesdescCollection = tgenemessagetemplatesdescCollection;
    }

    @XmlTransient
    public Collection<Tgenechannelsdesc> getTgenechannelsdescCollection() {
        return tgenechannelsdescCollection;
    }

    public void setTgenechannelsdescCollection(Collection<Tgenechannelsdesc> tgenechannelsdescCollection) {
        this.tgenechannelsdescCollection = tgenechannelsdescCollection;
    }

    @XmlTransient
    public Collection<Tgenesubproductdesc> getTgenesubproductdescCollection() {
        return tgenesubproductdescCollection;
    }

    public void setTgenesubproductdescCollection(Collection<Tgenesubproductdesc> tgenesubproductdescCollection) {
        this.tgenesubproductdescCollection = tgenesubproductdescCollection;
    }

    @XmlTransient
    public Collection<Tgenecitydesc> getTgenecitydescCollection() {
        return tgenecitydescCollection;
    }

    public void setTgenecitydescCollection(Collection<Tgenecitydesc> tgenecitydescCollection) {
        this.tgenecitydescCollection = tgenecitydescCollection;
    }

    @XmlTransient
    public Collection<Tgenecredittypedesc> getTgenecredittypedescCollection() {
        return tgenecredittypedescCollection;
    }

    public void setTgenecredittypedescCollection(Collection<Tgenecredittypedesc> tgenecredittypedescCollection) {
        this.tgenecredittypedescCollection = tgenecredittypedescCollection;
    }

    @XmlTransient
    public Collection<Tgenetransactiondesc> getTgenetransactiondescCollection() {
        return tgenetransactiondescCollection;
    }

    public void setTgenetransactiondescCollection(Collection<Tgenetransactiondesc> tgenetransactiondescCollection) {
        this.tgenetransactiondescCollection = tgenetransactiondescCollection;
    }

    @XmlTransient
    public Collection<Tgenefrequencydesc> getTgenefrequencydescCollection() {
        return tgenefrequencydescCollection;
    }

    public void setTgenefrequencydescCollection(Collection<Tgenefrequencydesc> tgenefrequencydescCollection) {
        this.tgenefrequencydescCollection = tgenefrequencydescCollection;
    }

    @XmlTransient
    public Collection<Tegenecantondesc> getTegenecantondescCollection() {
        return tegenecantondescCollection;
    }

    public void setTegenecantondescCollection(Collection<Tegenecantondesc> tegenecantondescCollection) {
        this.tegenecantondescCollection = tegenecantondescCollection;
    }

    @XmlTransient
    public Collection<Tgenemoduledesc> getTgenemoduledescCollection() {
        return tgenemoduledescCollection;
    }

    public void setTgenemoduledescCollection(Collection<Tgenemoduledesc> tgenemoduledescCollection) {
        this.tgenemoduledescCollection = tgenemoduledescCollection;
    }

    @XmlTransient
    public Collection<Tgenecatalogdetaildesc> getTgenecatalogdetaildescCollection() {
        return tgenecatalogdetaildescCollection;
    }

    public void setTgenecatalogdetaildescCollection(Collection<Tgenecatalogdetaildesc> tgenecatalogdetaildescCollection) {
        this.tgenecatalogdetaildescCollection = tgenecatalogdetaildescCollection;
    }

    @XmlTransient
    public Collection<Tgenetransactionglosary> getTgenetransactionglosaryCollection() {
        return tgenetransactionglosaryCollection;
    }

    public void setTgenetransactionglosaryCollection(Collection<Tgenetransactionglosary> tgenetransactionglosaryCollection) {
        this.tgenetransactionglosaryCollection = tgenetransactionglosaryCollection;
    }

    @XmlTransient
    public Collection<Tgenebalancetypedesc> getTgenebalancetypedescCollection() {
        return tgenebalancetypedescCollection;
    }

    public void setTgenebalancetypedescCollection(Collection<Tgenebalancetypedesc> tgenebalancetypedescCollection) {
        this.tgenebalancetypedescCollection = tgenebalancetypedescCollection;
    }

    @XmlTransient
    public Collection<Tgenebalancegroupdesc> getTgenebalancegroupdescCollection() {
        return tgenebalancegroupdescCollection;
    }

    public void setTgenebalancegroupdescCollection(Collection<Tgenebalancegroupdesc> tgenebalancegroupdescCollection) {
        this.tgenebalancegroupdescCollection = tgenebalancegroupdescCollection;
    }

    @XmlTransient
    public Collection<Tgeneprovincedesc> getTgeneprovincedescCollection() {
        return tgeneprovincedescCollection;
    }

    public void setTgeneprovincedescCollection(Collection<Tgeneprovincedesc> tgeneprovincedescCollection) {
        this.tgeneprovincedescCollection = tgeneprovincedescCollection;
    }

    @XmlTransient
    public Collection<Tgeneprocessdesc> getTgeneprocessdescCollection() {
        return tgeneprocessdescCollection;
    }

    public void setTgeneprocessdescCollection(Collection<Tgeneprocessdesc> tgeneprocessdescCollection) {
        this.tgeneprocessdescCollection = tgeneprocessdescCollection;
    }

    @XmlTransient
    public Collection<Tgenelabel> getTgenelabelCollection() {
        return tgenelabelCollection;
    }

    public void setTgenelabelCollection(Collection<Tgenelabel> tgenelabelCollection) {
        this.tgenelabelCollection = tgenelabelCollection;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (languagecode != null ? languagecode.hashCode() : 0);
        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 Tgenelanguage)) {
            return false;
        }
        Tgenelanguage other = (Tgenelanguage) object;
        if ((this.languagecode == null && other.languagecode != null) || (this.languagecode != null && !this.languagecode.equals(other.languagecode))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.qsoft.rs.sincoar.model.Tgenelanguage[ languagecode=" + languagecode + " ]";
    }
    
}
