107 lines
3.1 KiB
Java
107 lines
3.1 KiB
Java
/*
|
|
* To change this template, choose Tools | Templates
|
|
* and open the template in the editor.
|
|
*/
|
|
package com.rjconsultores.ventaboletos.entidad;
|
|
|
|
import java.io.Serializable;
|
|
import java.math.BigDecimal;
|
|
import javax.persistence.Basic;
|
|
import javax.persistence.Column;
|
|
import javax.persistence.Entity;
|
|
import javax.persistence.Id;
|
|
import javax.persistence.JoinColumn;
|
|
import javax.persistence.ManyToOne;
|
|
import javax.persistence.NamedQueries;
|
|
import javax.persistence.NamedQuery;
|
|
import javax.persistence.Table;
|
|
import javax.xml.bind.annotation.XmlRootElement;
|
|
|
|
/**
|
|
*
|
|
* @author gleimar
|
|
*/
|
|
@Entity
|
|
@Table(name = "SEGURO_TARIFA")
|
|
public class SeguroTarifa implements Serializable {
|
|
private static final long serialVersionUID = 1L;
|
|
@Id
|
|
@Basic(optional = false)
|
|
@Column(name = "SEGUROTARIFA_ID")
|
|
private Integer segurotarifaId;
|
|
// @Max(value=?) @Min(value=?)//if you know range of your decimal fields consider using these annotations to enforce field validation
|
|
@Column(name = "VALORTARIFA")
|
|
private BigDecimal valortarifa;
|
|
@Column(name = "VALORTARIFAATE")
|
|
private BigDecimal valortarifaate;
|
|
@JoinColumn(name = "ORGAOCONCEDENTE_ID", referencedColumnName = "ORGAOCONCEDENTE_ID")
|
|
@ManyToOne
|
|
private OrgaoConcedente orgaoconcedenteId;
|
|
|
|
public SeguroTarifa() {
|
|
}
|
|
|
|
public SeguroTarifa(Integer segurotarifaId) {
|
|
this.segurotarifaId = segurotarifaId;
|
|
}
|
|
|
|
public Integer getSegurotarifaId() {
|
|
return segurotarifaId;
|
|
}
|
|
|
|
public void setSegurotarifaId(Integer segurotarifaId) {
|
|
this.segurotarifaId = segurotarifaId;
|
|
}
|
|
|
|
public BigDecimal getValortarifa() {
|
|
return valortarifa;
|
|
}
|
|
|
|
public void setValortarifa(BigDecimal valortarifa) {
|
|
this.valortarifa = valortarifa;
|
|
}
|
|
|
|
|
|
public OrgaoConcedente getOrgaoconcedenteId() {
|
|
return orgaoconcedenteId;
|
|
}
|
|
|
|
public void setOrgaoconcedenteId(OrgaoConcedente orgaoconcedenteId) {
|
|
this.orgaoconcedenteId = orgaoconcedenteId;
|
|
}
|
|
|
|
@Override
|
|
public int hashCode() {
|
|
int hash = 0;
|
|
hash += (segurotarifaId != null ? segurotarifaId.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 SeguroTarifa)) {
|
|
return false;
|
|
}
|
|
SeguroTarifa other = (SeguroTarifa) object;
|
|
if ((this.segurotarifaId == null && other.segurotarifaId != null) || (this.segurotarifaId != null && !this.segurotarifaId.equals(other.segurotarifaId))) {
|
|
return false;
|
|
}
|
|
return true;
|
|
}
|
|
|
|
@Override
|
|
public String toString() {
|
|
return "com.rjconsultores.ventaboletos.entidad.SeguroTarifa[ segurotarifaId=" + segurotarifaId + " ]";
|
|
}
|
|
|
|
public BigDecimal getValortarifaate() {
|
|
return valortarifaate;
|
|
}
|
|
|
|
public void setValortarifaate(BigDecimal valortarifaate) {
|
|
this.valortarifaate = valortarifaate;
|
|
}
|
|
|
|
}
|