【Java开源代码栏目提醒】:本文主要为网学会员提供Advances.java,希望对需要Advances.java网友有所帮助,学习一下!
package com.myad.model;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.Date;
/**
* @struts.form include-all="true" extends="BaseForm"
* @hibernate.class table="advances"
*
*/
public class Advances extends BaseObject {
//字段
private String advancesid;
private String customerid;
private BigDecimal advancesamt;
private Timestamp advancesdate;
private String collectiondescription;
// Constructors
/** 缺省构造器 */
public Advances() {
}
/** 完整构造器 **/
public Advances(String customerid, BigDecimal advancesamt,
Timestamp advancesdate, String collectiondescription) {
this.customerid = customerid;
this.advancesamt = advancesamt;
this.advancesdate = advancesdate;
this.collectiondescription = collectiondescription;
}
//属性访问
/**
* *
*
* @hibernate.id generator-class="native" type="java.lang.String"
* column="advancesid"
*
*/
public String getAdvancesid() {
return this.advancesid;
}
public void setAdvancesid(String advancesid) {
this.advancesid = advancesid;
}
/**
* *
*
* @hibernate.property column="customerid" length="32"
*
*/
public String getCustomerid() {
return this.customerid;
}
public void setCustomerid(String customerid) {
this.customerid = customerid;
}
/**
* *
*
* @hibernate.property column="advancesamt" length="15"
*
*/
public BigDecimal getAdvancesamt() {
return this.advancesamt;
}
public void setAdvancesamt(BigDecimal advancesamt) {
this.advancesamt = advancesamt;
}
/**
* *
*
* @hibernate.property column="advancesdate" length="19"
*
*/
public Timestamp getAdvancesdate() {
return this.advancesdate;
}
public void setAdvancesdate(Timestamp advancesdate) {
this.advancesdate = advancesdate;
}
/**
* *
*
* @hibernate.property column="collectiondescription" length="255"
*
*/
public String getCollectiondescription() {
return this.collectiondescription;
}
public void setCollectiondescription(String collectiondescription) {
this.collectiondescription = collectiondescription;
}
/**
* toString
*
* @return String
*/
public String toString() {
StringBuffer buffer = new StringBuffer();
buffer.append(getClass().getName()).append("@").append(
Integer.toHexString(hashCode())).append(" [");
buffer.append("customerid").append("='").append(getCustomerid())
.append("' ");
buffer.append("advancesamt").append("='").append(getAdvancesamt())
.append("' ");
buffer.append("advancesdate").append("='").append(getAdvancesdate())
.append("' ");
buffer.append("collectiondescription").append("='").append(
getCollectiondescription()).append("' ");
buffer.append("]");
return buffer.toString();
}
public boolean equals(Object other) {
if ((this == other))
return true;
if ((other == null))
return false;
if (!(other instanceof Advances))
return false;
Advances castOther = (Advances) other;
return ((this.getAdvancesid() == castOther.getAdvancesid()) || (this
.getAdvancesid() != null
&& castOther.getAdvancesid() != null && this.getAdvancesid()
.equals(castOther.getAdvancesid())))
&& ((this.getCustomerid() == castOther.getCustomerid()) || (this
.getCustomerid() != null
&& castOther.getCustomerid() != null && this
.getCustomerid().equals(castOther.getCustomerid())))
&& ((this.getAdvancesamt() == castOther.getAdvancesamt()) || (this
.getAdvancesamt() != null
&& castOther.getAdvancesamt() != null && this
.getAdvancesamt().equals(castOther.getAdvancesamt())))
&& ((this.getAdvancesdate() == castOther.getAdvancesdate()) || (this
.getAdvancesdate() != null
&& castOther.getAdvancesdate() != null && this
.getAdvancesdate().equals(castOther.getAdvancesdate())))
&& ((this.getCollectiondescription() == castOther
.getCollectiondescription()) || (this
.getCollectiondescription() != null
&& castOther.getCollectiondescription() != null && this
.getCollectiondescription().equals(
castOther.getCollectiondescription())));
}
public int hashCode() {
int result = 17;
result = 37
* result
+ (getAdvancesid() == null ? 0 : this.getAdvancesid()
.hashCode());
result = 37
* result
+ (getCustomerid() == null ? 0 : this.getCustomerid()
.hashCode());
result = 37
* result
+ (getAdvancesamt() == null ? 0 : this.getAdvancesamt()
.hashCode());
result = 37
* result
+ (getAdvancesdate() == null ? 0 : this.getAdvancesdate()
.hashCode());
result = 37
* result
+ (getCollectiondescription() == null ? 0 : this
.getCollectiondescription().hashCode());
return result;
}
}
上一篇:
AdvancedSearchDialog.java
下一篇:
经济酒店发展:China''s economy hotel market development strategies