package com.fitbank.hb.persistence.lote;

import java.io.Serializable;
import java.lang.reflect.Field;
import java.sql.Date;

/**Clase que hace referencia a la Clave Primaria de TLOTECAMPOSREQUERIDOSVALOR*/
public class TrequiredlotfieldsvalueKey    implements Serializable,Cloneable{
/** Nombre de la Tabla TLOTECAMPOSREQUERIDOSVALOR */
public static final String TABLE_NAME = "TLOTECAMPOSREQUERIDOSVALOR";
/** HashCode asociado con la Instancia*/
private int hashValue = 0;
/** Version de la Clase*/
private static final long serialVersionUID = 1L;
/**
* Fecha del lote de transacciones
*/
private Date fechalote;

/**
* Numero del lote de transacciones consecutrivo para la fecha
*/
private Integer numerolote;

/**
* Nombre de la estructura
*/
private String cloteestructura;

/**
* Numero consecutivo del campo requerido por el lote
*/
private Integer slotecamporequerido;

/**Contructor por defecto*/
public TrequiredlotfieldsvalueKey(){}
/**Contructor de TrequiredlotfieldsvalueKey
@param pFechalote Fecha del lote de transacciones
@param pNumerolote Numero del lote de transacciones consecutrivo para la fecha
@param pCloteestructura Nombre de la estructura
@param pSlotecamporequerido Numero consecutivo del campo requerido por el lote
*/
public TrequiredlotfieldsvalueKey(Date pFechalote,Integer pNumerolote,String pCloteestructura,Integer pSlotecamporequerido){
 fechalote=pFechalote;
 numerolote=pNumerolote;
 cloteestructura=pCloteestructura;
 slotecamporequerido=pSlotecamporequerido;
}
public static final String FECHALOTE="FECHALOTE";
/**Obtiene el valor de fechalote
@return valor de fechalote*/
public Date getFechalote(){
  return fechalote;
}
/**Fija el valor de fechalote
@param pFechalote nuevo Valor de fechalote*/
public void setFechalote(Date pFechalote){
  fechalote=pFechalote;
}

public static final String NUMEROLOTE="NUMEROLOTE";
/**Obtiene el valor de numerolote
@return valor de numerolote*/
public Integer getNumerolote(){
  return numerolote;
}
/**Fija el valor de numerolote
@param pNumerolote nuevo Valor de numerolote*/
public void setNumerolote(Integer pNumerolote){
  numerolote=pNumerolote;
}

public static final String CLOTEESTRUCTURA="CLOTEESTRUCTURA";
/**Obtiene el valor de cloteestructura
@return valor de cloteestructura*/
public String getCloteestructura(){
  return cloteestructura;
}
/**Fija el valor de cloteestructura
@param pCloteestructura nuevo Valor de cloteestructura*/
public void setCloteestructura(String pCloteestructura){
  cloteestructura=pCloteestructura;
}

public static final String SLOTECAMPOREQUERIDO="SLOTECAMPOREQUERIDO";
/**Obtiene el valor de slotecamporequerido
@return valor de slotecamporequerido*/
public Integer getSlotecamporequerido(){
  return slotecamporequerido;
}
/**Fija el valor de slotecamporequerido
@param pSlotecamporequerido nuevo Valor de slotecamporequerido*/
public void setSlotecamporequerido(Integer pSlotecamporequerido){
  slotecamporequerido=pSlotecamporequerido;
}

public static final String PK_FECHALOTE="FECHALOTE";
public static final String PK_NUMEROLOTE="NUMEROLOTE";
public static final String PK_CLOTEESTRUCTURA="CLOTEESTRUCTURA";
public static final String PK_SLOTECAMPOREQUERIDO="SLOTECAMPOREQUERIDO";
/**Implementaciï¿½n de la comparaciï¿½n de TrequiredlotfieldsvalueKey
@param o Objeto de comparaciÃ¯Â¿Â½n
*/
public boolean equals(Object o){
  if (o == null){return false;}
  if (! (o instanceof TrequiredlotfieldsvalueKey)){return false;}
  TrequiredlotfieldsvalueKey that = (TrequiredlotfieldsvalueKey) o;
  if (this.getFechalote() == null || that.getFechalote() == null){
      return false;
  }
  if (! this.getFechalote().equals(that.getFechalote())){
    return false;
  }
  if (this.getNumerolote() == null || that.getNumerolote() == null){
      return false;
  }
  if (! this.getNumerolote().equals(that.getNumerolote())){
    return false;
  }
  if (this.getCloteestructura() == null || that.getCloteestructura() == null){
      return false;
  }
  if (! this.getCloteestructura().equals(that.getCloteestructura())){
    return false;
  }
  if (this.getSlotecamporequerido() == null || that.getSlotecamporequerido() == null){
      return false;
  }
  if (! this.getSlotecamporequerido().equals(that.getSlotecamporequerido())){
    return false;
  }
  return true;
}
/**Implementaciï¿½n del mï¿½todo hashCode bajo el patrï¿½n de Bloch
@return hashCode de la instancia TrequiredlotfieldsvalueKey
*/
public int hashCode(){
  if (this.hashValue == 0){
    int result = 17;
    result = result * 37 + (this.getFechalote() == null ? 0 : this.getFechalote().hashCode());
    result = result * 37 + (this.getNumerolote() == null ? 0 : this.getNumerolote().hashCode());
    result = result * 37 + (this.getCloteestructura() == null ? 0 : this.getCloteestructura().hashCode());
    result = result * 37 + (this.getSlotecamporequerido() == null ? 0 : this.getSlotecamporequerido().hashCode());
    this.hashValue = result;
  }
  return this.hashValue;
}
public Object cloneMe() throws Exception {
  return this.clone();
}
/**Implementaciï¿½n toString
*/
public String toString() {
	Field[]fs=this.getClass().getDeclaredFields();
	String data="";
	for(Field f:fs){
	 try{	
	 String name=f.getName();
	 if(name.compareTo("hashValue")==0||name.compareTo("serialVersionUID")==0){continue;}
		data+="pk."+name+"="+f.get(this)+";";
	 }catch(Exception e){
		 continue;
	 }
		}
		if(data.compareTo("")==0){
		data=super.toString();
		}
	return data;
	}
}
