/*
 * 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.math.BigInteger;
import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author developer2
 */
@Entity
@Table(name="COMACO.TGENEDICTIONARY")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "Tgenedictionary.findAll", query = "SELECT t FROM Tgenedictionary t"),
    @NamedQuery(name = "Tgenedictionary.findByTablename", query = "SELECT t FROM Tgenedictionary t WHERE t.tgenedictionaryPK.tablename = :tablename"),
    @NamedQuery(name = "Tgenedictionary.findByColumnname", query = "SELECT t FROM Tgenedictionary t WHERE t.tgenedictionaryPK.columnname = :columnname"),
    @NamedQuery(name = "Tgenedictionary.findByRecordversion", query = "SELECT t FROM Tgenedictionary t WHERE t.recordversion = :recordversion"),
    @NamedQuery(name = "Tgenedictionary.findByDescription", query = "SELECT t FROM Tgenedictionary t WHERE t.description = :description")})
public class Tgenedictionary implements Serializable {

    private static final long serialVersionUID = 1L;
    @EmbeddedId
    protected TgenedictionaryPK tgenedictionaryPK;
    @Column(name = "RECORDVERSION")
    private BigInteger recordversion;
    @Column(name = "DESCRIPTION")
    private String description;

    public Tgenedictionary() {
    }

    public Tgenedictionary(TgenedictionaryPK tgenedictionaryPK) {
        this.tgenedictionaryPK = tgenedictionaryPK;
    }

    public Tgenedictionary(String tablename, String columnname) {
        this.tgenedictionaryPK = new TgenedictionaryPK(tablename, columnname);
    }

    public TgenedictionaryPK getTgenedictionaryPK() {
        return tgenedictionaryPK;
    }

    public void setTgenedictionaryPK(TgenedictionaryPK tgenedictionaryPK) {
        this.tgenedictionaryPK = tgenedictionaryPK;
    }

    public BigInteger getRecordversion() {
        return recordversion;
    }

    public void setRecordversion(BigInteger recordversion) {
        this.recordversion = recordversion;
    }

    public String getDescription() {
        return description;
    }

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

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

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