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

/**
 *
 * @author developer2
 */
@Entity
@Table(name="COMACO.TGENESEQUENCES")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "Tgenesequences.findAll", query = "SELECT t FROM Tgenesequences t"),
    @NamedQuery(name = "Tgenesequences.findByCode", query = "SELECT t FROM Tgenesequences t WHERE t.code = :code"),
    @NamedQuery(name = "Tgenesequences.findByCurrentvalue", query = "SELECT t FROM Tgenesequences t WHERE t.currentvalue = :currentvalue"),
    @NamedQuery(name = "Tgenesequences.findByInitialvalue", query = "SELECT t FROM Tgenesequences t WHERE t.initialvalue = :initialvalue"),
    @NamedQuery(name = "Tgenesequences.findByLastvalue", query = "SELECT t FROM Tgenesequences t WHERE t.lastvalue = :lastvalue"),
    @NamedQuery(name = "Tgenesequences.findByCyclic", query = "SELECT t FROM Tgenesequences t WHERE t.cyclic = :cyclic"),
    @NamedQuery(name = "Tgenesequences.findByIncrease", query = "SELECT t FROM Tgenesequences t WHERE t.increase = :increase")})
public class Tgenesequences implements Serializable {

    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "CODE")
    private String code;
    @Basic(optional = false)
    @Column(name = "CURRENTVALUE")
    private BigInteger currentvalue;
    @Basic(optional = false)
    @Column(name = "INITIALVALUE")
    private BigInteger initialvalue;
    @Basic(optional = false)
    @Column(name = "LASTVALUE")
    private BigInteger lastvalue;
    @Column(name = "CYCLIC")
    private String cyclic;
    @Basic(optional = false)
    @Column(name = "INCREASE")
    private int increase;

    public Tgenesequences() {
    }

    public Tgenesequences(String code) {
        this.code = code;
    }

    public Tgenesequences(String code, BigInteger currentvalue, BigInteger initialvalue, BigInteger lastvalue, int increase) {
        this.code = code;
        this.currentvalue = currentvalue;
        this.initialvalue = initialvalue;
        this.lastvalue = lastvalue;
        this.increase = increase;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public BigInteger getCurrentvalue() {
        return currentvalue;
    }

    public void setCurrentvalue(BigInteger currentvalue) {
        this.currentvalue = currentvalue;
    }

    public BigInteger getInitialvalue() {
        return initialvalue;
    }

    public void setInitialvalue(BigInteger initialvalue) {
        this.initialvalue = initialvalue;
    }

    public BigInteger getLastvalue() {
        return lastvalue;
    }

    public void setLastvalue(BigInteger lastvalue) {
        this.lastvalue = lastvalue;
    }

    public String getCyclic() {
        return cyclic;
    }

    public void setCyclic(String cyclic) {
        this.cyclic = cyclic;
    }

    public int getIncrease() {
        return increase;
    }

    public void setIncrease(int increase) {
        this.increase = increase;
    }

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

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