436 lines
12 KiB
Plaintext
Executable File
436 lines
12 KiB
Plaintext
Executable File
package com.fp.persistence.pcustomer.people;
|
||
|
||
import java.sql.Timestamp;
|
||
import com.fp.dto.hb.Log;
|
||
import java.io.Serializable;
|
||
import javax.persistence.Table;
|
||
import java.math.BigDecimal;
|
||
import com.fp.dto.hb.HibernateBean;
|
||
import javax.persistence.Version;
|
||
import javax.persistence.Entity;
|
||
import javax.persistence.EmbeddedId;
|
||
import javax.persistence.EntityManager;
|
||
import javax.persistence.Column;
|
||
import java.lang.reflect.Field;
|
||
import javax.persistence.Transient;
|
||
|
||
/**Clase que implementa la entidad de Hibernate que hace referencia a la tabla TCUSTPEOPLEADITIONALDATA*/
|
||
@Entity(name="TcustPeopleAditionalData")
|
||
@Table(name="TCUSTPEOPLEADITIONALDATA")
|
||
public class TcustPeopleAditionalData extends com.fp.dto.AbstractDataTransport implements Serializable,HibernateBean,Cloneable,Log{
|
||
/**
|
||
* HashCode asociado con la Instancia
|
||
*/
|
||
@Transient
|
||
private int hashValue = 0;
|
||
/**
|
||
* Version de la Clase
|
||
*/
|
||
private static final long serialVersionUID = 1L;
|
||
/**
|
||
* Clave primaria de la Entidad TcustPeopleAditionalData
|
||
*/
|
||
@EmbeddedId
|
||
private TcustPeopleAditionalDataKey pk;
|
||
@Column(name="DATEFROM", nullable=true)
|
||
|
||
/**
|
||
* Fecha desde la cual esta vigente el registro
|
||
*/
|
||
private Timestamp datefrom;
|
||
|
||
@Version
|
||
@Column(name="RECORDVERSION", nullable=true)
|
||
|
||
/**
|
||
* Optimistic locking del registro
|
||
*/
|
||
private Integer recordversion;
|
||
|
||
@Column(name="HOMETYPECATALOG", nullable=true)
|
||
|
||
/**
|
||
* Codigo de catalogo P Propia, A alquidada, F familiares
|
||
*/
|
||
private String hometypecatalog;
|
||
|
||
@Column(name="HOMETYPECATALOGCODE", nullable=true)
|
||
|
||
/**
|
||
* Codigo de tabla de catalogo HOMETYPE tipo de vivienda.
|
||
*/
|
||
private String hometypecatalogcode;
|
||
|
||
@Column(name="IDENTIFICATIONCATALOG", nullable=true)
|
||
|
||
/**
|
||
* Codigo de catalogo CED cedula, RUC ruc identificacion adicional del cliente.
|
||
*/
|
||
private String identificationcatalog;
|
||
|
||
@Column(name="IDENTIFICATIONCATALOGCODE", nullable=true)
|
||
|
||
/**
|
||
* Codigo de tabla de catalogo IDENTIFICATION tipo de identificacion
|
||
*/
|
||
private String identificationcatalogcode;
|
||
|
||
@Column(name="IDENTIFICATION", nullable=true)
|
||
|
||
/**
|
||
* Numero de cedula, ruc, pasaporte, etc..
|
||
*/
|
||
private String identification;
|
||
|
||
@Column(name="JOBRELATIONSHIPCATALOG", nullable=true)
|
||
|
||
/**
|
||
* Codigo de catalogo 1 dependiente, 2 Independiente, 3 jubilado
|
||
*/
|
||
private String jobrelationshipcatalog;
|
||
|
||
@Column(name="JOBRELATIONSHIPCATALOGCODE", nullable=true)
|
||
|
||
/**
|
||
* Codigo de tabla de catalogo JOBRELATIONSHIP relacion labolar
|
||
*/
|
||
private String jobrelationshipcatalogcode;
|
||
|
||
@Column(name="WORKERSNUMBER", nullable=true)
|
||
|
||
/**
|
||
* Numero de empledos.
|
||
*/
|
||
private Integer workersnumber;
|
||
|
||
@Column(name="DEPENDENTSNUMBER", nullable=true)
|
||
|
||
/**
|
||
* Numero de dependientes.
|
||
*/
|
||
private Integer dependentsnumber;
|
||
|
||
@Column(name="INGRESSUSERCODE", nullable=true)
|
||
|
||
/**
|
||
* Codigo de usuario
|
||
*/
|
||
private String ingressusercode;
|
||
|
||
@Column(name="MODIFYUSERCODE", nullable=true)
|
||
|
||
/**
|
||
* Codigo de usuario
|
||
*/
|
||
private String modifyusercode;
|
||
|
||
@Column(name="HOMEVALUE", nullable=true)
|
||
|
||
/**
|
||
* Valor de la vivienda
|
||
*/
|
||
private BigDecimal homevalue;
|
||
|
||
@Column(name="HOMERESIDENCETIME", nullable=true)
|
||
|
||
/**
|
||
* A<>os de residencia en la vivienda actual
|
||
*/
|
||
private Integer homeresidencetime;
|
||
|
||
@Column(name="MAINSOURCEINCOMECATALOG", nullable=true)
|
||
|
||
/**
|
||
* null
|
||
*/
|
||
private String mainsourceincomecatalog;
|
||
|
||
@Column(name="MAINSOURCEINCOMECATALOGCODE", nullable=true)
|
||
|
||
/**
|
||
* null
|
||
*/
|
||
private String mainsourceincomecatalogcode;
|
||
|
||
/**Contructor por defecto*/
|
||
public TcustPeopleAditionalData(){
|
||
}
|
||
/**Contructor de TcustPeopleAditionalData
|
||
@param pPk Clave Primaria del entity
|
||
*/
|
||
public TcustPeopleAditionalData(TcustPeopleAditionalDataKey pPk){
|
||
this();
|
||
pk=pPk;
|
||
}
|
||
/**
|
||
* Metodo que entrega datos de la tabla dada la clave primaria.
|
||
* @param pEntityManager referencia de la session a obtener datos del bean.
|
||
* @param pKey Caleve primaria del bean.
|
||
* @return TcustPeopleAditionalData
|
||
*/
|
||
public static TcustPeopleAditionalData find(EntityManager pEntityManager,TcustPeopleAditionalDataKey pKey) throws Exception{
|
||
TcustPeopleAditionalData obj = pEntityManager.find(TcustPeopleAditionalData.class,pKey);
|
||
return obj;
|
||
}
|
||
/**Entrega la Clave primaria de TcustPeopleAditionalData
|
||
@return El objeto que referencia a la Clave primaria de TcustPeopleAditionalData
|
||
*/
|
||
public TcustPeopleAditionalDataKey getPk(){
|
||
return pk;
|
||
}
|
||
/**Fija un nuevo valor a la Clave primaria de TcustPeopleAditionalData
|
||
@param pPk El objeto que referencia a la nueva Clave primaria de TcustPeopleAditionalData
|
||
*/
|
||
public void setPk(TcustPeopleAditionalDataKey pPk){
|
||
pk=pPk;
|
||
}
|
||
/**Obtiene el valor de datefrom
|
||
@return valor de datefrom*/
|
||
public Timestamp getDatefrom(){
|
||
return datefrom;
|
||
}
|
||
/**Fija el valor de datefrom
|
||
@param pDatefrom nuevo Valor de datefrom*/
|
||
public void setDatefrom(Timestamp pDatefrom){
|
||
datefrom=pDatefrom;
|
||
}
|
||
|
||
/**Obtiene el valor de recordversion
|
||
@return valor de recordversion*/
|
||
public Integer getRecordversion(){
|
||
return recordversion;
|
||
}
|
||
/**Fija el valor de recordversion
|
||
@param pRecordversion nuevo Valor de recordversion*/
|
||
public void setRecordversion(Integer pRecordversion){
|
||
recordversion=pRecordversion;
|
||
}
|
||
|
||
/**Obtiene el valor de hometypecatalog
|
||
@return valor de hometypecatalog*/
|
||
public String getHometypecatalog(){
|
||
return hometypecatalog;
|
||
}
|
||
/**Fija el valor de hometypecatalog
|
||
@param pHometypecatalog nuevo Valor de hometypecatalog*/
|
||
public void setHometypecatalog(String pHometypecatalog){
|
||
hometypecatalog=pHometypecatalog;
|
||
}
|
||
|
||
/**Obtiene el valor de hometypecatalogcode
|
||
@return valor de hometypecatalogcode*/
|
||
public String getHometypecatalogcode(){
|
||
return hometypecatalogcode;
|
||
}
|
||
/**Fija el valor de hometypecatalogcode
|
||
@param pHometypecatalogcode nuevo Valor de hometypecatalogcode*/
|
||
public void setHometypecatalogcode(String pHometypecatalogcode){
|
||
hometypecatalogcode=pHometypecatalogcode;
|
||
}
|
||
|
||
/**Obtiene el valor de identificationcatalog
|
||
@return valor de identificationcatalog*/
|
||
public String getIdentificationcatalog(){
|
||
return identificationcatalog;
|
||
}
|
||
/**Fija el valor de identificationcatalog
|
||
@param pIdentificationcatalog nuevo Valor de identificationcatalog*/
|
||
public void setIdentificationcatalog(String pIdentificationcatalog){
|
||
identificationcatalog=pIdentificationcatalog;
|
||
}
|
||
|
||
/**Obtiene el valor de identificationcatalogcode
|
||
@return valor de identificationcatalogcode*/
|
||
public String getIdentificationcatalogcode(){
|
||
return identificationcatalogcode;
|
||
}
|
||
/**Fija el valor de identificationcatalogcode
|
||
@param pIdentificationcatalogcode nuevo Valor de identificationcatalogcode*/
|
||
public void setIdentificationcatalogcode(String pIdentificationcatalogcode){
|
||
identificationcatalogcode=pIdentificationcatalogcode;
|
||
}
|
||
|
||
/**Obtiene el valor de identification
|
||
@return valor de identification*/
|
||
public String getIdentification(){
|
||
return identification;
|
||
}
|
||
/**Fija el valor de identification
|
||
@param pIdentification nuevo Valor de identification*/
|
||
public void setIdentification(String pIdentification){
|
||
identification=pIdentification;
|
||
}
|
||
|
||
/**Obtiene el valor de jobrelationshipcatalog
|
||
@return valor de jobrelationshipcatalog*/
|
||
public String getJobrelationshipcatalog(){
|
||
return jobrelationshipcatalog;
|
||
}
|
||
/**Fija el valor de jobrelationshipcatalog
|
||
@param pJobrelationshipcatalog nuevo Valor de jobrelationshipcatalog*/
|
||
public void setJobrelationshipcatalog(String pJobrelationshipcatalog){
|
||
jobrelationshipcatalog=pJobrelationshipcatalog;
|
||
}
|
||
|
||
/**Obtiene el valor de jobrelationshipcatalogcode
|
||
@return valor de jobrelationshipcatalogcode*/
|
||
public String getJobrelationshipcatalogcode(){
|
||
return jobrelationshipcatalogcode;
|
||
}
|
||
/**Fija el valor de jobrelationshipcatalogcode
|
||
@param pJobrelationshipcatalogcode nuevo Valor de jobrelationshipcatalogcode*/
|
||
public void setJobrelationshipcatalogcode(String pJobrelationshipcatalogcode){
|
||
jobrelationshipcatalogcode=pJobrelationshipcatalogcode;
|
||
}
|
||
|
||
/**Obtiene el valor de workersnumber
|
||
@return valor de workersnumber*/
|
||
public Integer getWorkersnumber(){
|
||
return workersnumber;
|
||
}
|
||
/**Fija el valor de workersnumber
|
||
@param pWorkersnumber nuevo Valor de workersnumber*/
|
||
public void setWorkersnumber(Integer pWorkersnumber){
|
||
workersnumber=pWorkersnumber;
|
||
}
|
||
|
||
/**Obtiene el valor de dependentsnumber
|
||
@return valor de dependentsnumber*/
|
||
public Integer getDependentsnumber(){
|
||
return dependentsnumber;
|
||
}
|
||
/**Fija el valor de dependentsnumber
|
||
@param pDependentsnumber nuevo Valor de dependentsnumber*/
|
||
public void setDependentsnumber(Integer pDependentsnumber){
|
||
dependentsnumber=pDependentsnumber;
|
||
}
|
||
|
||
/**Obtiene el valor de ingressusercode
|
||
@return valor de ingressusercode*/
|
||
public String getIngressusercode(){
|
||
return ingressusercode;
|
||
}
|
||
/**Fija el valor de ingressusercode
|
||
@param pIngressusercode nuevo Valor de ingressusercode*/
|
||
public void setIngressusercode(String pIngressusercode){
|
||
ingressusercode=pIngressusercode;
|
||
}
|
||
|
||
/**Obtiene el valor de modifyusercode
|
||
@return valor de modifyusercode*/
|
||
public String getModifyusercode(){
|
||
return modifyusercode;
|
||
}
|
||
/**Fija el valor de modifyusercode
|
||
@param pModifyusercode nuevo Valor de modifyusercode*/
|
||
public void setModifyusercode(String pModifyusercode){
|
||
modifyusercode=pModifyusercode;
|
||
}
|
||
|
||
/**Obtiene el valor de homevalue
|
||
@return valor de homevalue*/
|
||
public BigDecimal getHomevalue(){
|
||
return homevalue;
|
||
}
|
||
/**Fija el valor de homevalue
|
||
@param pHomevalue nuevo Valor de homevalue*/
|
||
public void setHomevalue(BigDecimal pHomevalue){
|
||
homevalue=pHomevalue;
|
||
}
|
||
|
||
/**Obtiene el valor de homeresidencetime
|
||
@return valor de homeresidencetime*/
|
||
public Integer getHomeresidencetime(){
|
||
return homeresidencetime;
|
||
}
|
||
/**Fija el valor de homeresidencetime
|
||
@param pHomeresidencetime nuevo Valor de homeresidencetime*/
|
||
public void setHomeresidencetime(Integer pHomeresidencetime){
|
||
homeresidencetime=pHomeresidencetime;
|
||
}
|
||
|
||
/**Obtiene el valor de mainsourceincomecatalog
|
||
@return valor de mainsourceincomecatalog*/
|
||
public String getMainsourceincomecatalog(){
|
||
return mainsourceincomecatalog;
|
||
}
|
||
/**Fija el valor de mainsourceincomecatalog
|
||
@param pMainsourceincomecatalog nuevo Valor de mainsourceincomecatalog*/
|
||
public void setMainsourceincomecatalog(String pMainsourceincomecatalog){
|
||
mainsourceincomecatalog=pMainsourceincomecatalog;
|
||
}
|
||
|
||
/**Obtiene el valor de mainsourceincomecatalogcode
|
||
@return valor de mainsourceincomecatalogcode*/
|
||
public String getMainsourceincomecatalogcode(){
|
||
return mainsourceincomecatalogcode;
|
||
}
|
||
/**Fija el valor de mainsourceincomecatalogcode
|
||
@param pMainsourceincomecatalogcode nuevo Valor de mainsourceincomecatalogcode*/
|
||
public void setMainsourceincomecatalogcode(String pMainsourceincomecatalogcode){
|
||
mainsourceincomecatalogcode=pMainsourceincomecatalogcode;
|
||
}
|
||
|
||
public boolean equals(Object rhs){
|
||
if (rhs == null)return false;
|
||
if (! (rhs instanceof TcustPeopleAditionalData))return false;
|
||
TcustPeopleAditionalData that = (TcustPeopleAditionalData) rhs;
|
||
if (this.getPk() == null || that.getPk() == null)
|
||
return false;
|
||
return (this.getPk().equals(that.getPk()));
|
||
}
|
||
/**Implementacion del metodo hashCode de la la entidad TcustPeopleAditionalData
|
||
@return el hashCode la instancia
|
||
*/
|
||
public int hashCode() {
|
||
if (this.hashValue == 0){
|
||
int result = 17;
|
||
if (this.getPk() == null){
|
||
result = super.hashCode();
|
||
}else{
|
||
result = this.getPk().hashCode();
|
||
}
|
||
this.hashValue = result;
|
||
}
|
||
return this.hashValue;
|
||
}
|
||
/**Implementacion toString
|
||
*/
|
||
public String toString() {
|
||
Field[]fs=this.getClass().getDeclaredFields();
|
||
String data="";
|
||
for(Field f:fs){
|
||
try{
|
||
String name=f.getName();
|
||
if(f.getType().getName().compareTo("java.util.Set")==0)continue;
|
||
if(name.compareTo("hashValue")==0||name.compareTo("serialVersionUID")==0)continue;
|
||
data+=name+"="+f.get(this)+";";
|
||
}catch(Exception e){
|
||
continue;
|
||
}
|
||
}
|
||
if(data.compareTo("")==0){
|
||
data=super.toString();
|
||
}
|
||
return data;
|
||
}
|
||
/**Implementacion de la creacion de un bean en blanco TcustPeopleAditionalData
|
||
*/
|
||
public Object createInstance(){
|
||
TcustPeopleAditionalData instance=new TcustPeopleAditionalData();
|
||
instance.setPk(new TcustPeopleAditionalDataKey());
|
||
return instance;
|
||
}
|
||
/**Clona la entidad TcustPeopleAditionalData
|
||
@see com.fp.dto.hb.HibernateBean#cloneMe()
|
||
*/
|
||
public Object cloneMe() throws CloneNotSupportedException{
|
||
TcustPeopleAditionalData p=(TcustPeopleAditionalData)this.clone();
|
||
p.setPk((TcustPeopleAditionalDataKey)this.pk.cloneMe());
|
||
return p;
|
||
}
|
||
public Object getId() {
|
||
return this.pk;
|
||
}
|
||
}
|