1) a pojo java class that extends a base pojo java class. That way if I have custome attributes I can put those in the user overridable pojo java class.
package com.xxx.olbmaint.business.domain.base;
import java.io.Serializable;
/**
* This class has been automatically generated by Hibernate Synchronizer.
* For more information or documentation, visit The Hibernate Synchronizer page
* at http://www.binamics.com/hibernatesync or contact Joe Hudson at
[email protected].
*
* This is an object that contains data related to the COVERAGE_PACKAGE_CODE table.
* Do not modify this class because it will be overwritten if the configuration file
* related to this class is modified.
*
* @hibernate.class
* table="COVERAGE_PACKAGE_CODE"
*/
public abstract class BaseCoveragePackageCode implements Serializable {
public static String PROP_COVERAGE_PACKAGE_CODE = "coveragePackageCode";
public static String PROP_END_DATE = "endDate";
public static String PROP_CONTAINED_IN_OLB = "containedInOlb";
public static String PROP_BEN_LIMIT_UR = "benLimitUr";
public static String PROP_EFFECTIVE_DATE = "effectiveDate";
private int hashCode = Integer.MIN_VALUE;
// primary key
private java.lang.String _coveragePackageCode;
// fields
private java.util.Date _effectiveDate;
private java.lang.String _benLimitUr;
private java.lang.String _containedInOlb;
private java.util.Date _endDate;
// collections
private java.util.Set _planPackageOdometers;
// constructors
public BaseCoveragePackageCode () {
initialize();
}
/**
* Constructor for primary key
*/
public BaseCoveragePackageCode (java.lang.String _coveragePackageCode) {
this.setCoveragePackageCode(_coveragePackageCode);
initialize();
}
/**
* Constructor for required fields
*/
public BaseCoveragePackageCode (
java.lang.String _coveragePackageCode,
java.lang.String _benLimitUr) {
this.setCoveragePackageCode(_coveragePackageCode);
this.setBenLimitUr(_benLimitUr);
initialize();
}
protected void initialize () {}
/**
* Return the unique identifier of this class
* @hibernate.id
* generator-class="uuid.hex"
* column="COVERAGE_PACKAGE_CODE"
*/
public java.lang.String getCoveragePackageCode () {
return _coveragePackageCode;
}
/**
* Set the unique identifier of this class
* @param _coveragePackageCode the new ID
*/
public void setCoveragePackageCode (java.lang.String _coveragePackageCode) {
this._coveragePackageCode = _coveragePackageCode;
this.hashCode = Integer.MIN_VALUE;
}
/**
* Return the value associated with the column: EFFECTIVE_DATE
*/
public java.util.Date getEffectiveDate () {
return _effectiveDate;
}
/**
* Set the value related to the column: EFFECTIVE_DATE
* @param _effectiveDate the EFFECTIVE_DATE value
*/
public void setEffectiveDate (java.util.Date _effectiveDate) {
this._effectiveDate = _effectiveDate;
}
/**
* Return the value associated with the column: BEN_LIMIT_UR
*/
public java.lang.String getBenLimitUr () {
return _benLimitUr;
}
/**
* Set the value related to the column: BEN_LIMIT_UR
* @param _benLimitUr the BEN_LIMIT_UR value
*/
public void setBenLimitUr (java.lang.String _benLimitUr) {
this._benLimitUr = _benLimitUr;
}
/**
* Return the value associated with the column: CONTAINED_IN_OLB
*/
public java.lang.String getContainedInOlb () {
return _containedInOlb;
}
/**
* Set the value related to the column: CONTAINED_IN_OLB
* @param _containedInOlb the CONTAINED_IN_OLB value
*/
public void setContainedInOlb (java.lang.String _containedInOlb) {
this._containedInOlb = _containedInOlb;
}
/**
* Return the value associated with the column: END_DATE
*/
public java.util.Date getEndDate () {
return _endDate;
}
/**
* Set the value related to the column: END_DATE
* @param _endDate the END_DATE value
*/
public void setEndDate (java.util.Date _endDate) {
this._endDate = _endDate;
}
/**
* Return the value associated with the column: planPackageOdometers
*/
public java.util.Set getPlanPackageOdometers () {
return this._planPackageOdometers;
}
/**
* Set the value related to the column: planPackageOdometers
* @param _planPackageOdometers the planPackageOdometers value
*/
public void setPlanPackageOdometers (java.util.Set _planPackageOdometers) {
this._planPackageOdometers = _planPackageOdometers;
}
public void addToPlanPackageOdometers (Object obj) {
if (null == this._planPackageOdometers) this._planPackageOdometers = new java.util.HashSet();
this._planPackageOdometers.add(obj);
}
public boolean equals (Object obj) {
if (null == obj) return false;
if (!(obj instanceof com.bcbsma.olbmaint.business.domain.base.BaseCoveragePackageCode)) return false;
else {
com.bcbsma.olbmaint.business.domain.base.BaseCoveragePackageCode mObj = (com.bcbsma.olbmaint.business.domain.base.BaseCoveragePackageCode) obj;
if (null == this.getCoveragePackageCode() || null == mObj.getCoveragePackageCode()) return false;
else return (this.getCoveragePackageCode().equals(mObj.getCoveragePackageCode()));
}
}
public int hashCode () {
if (Integer.MIN_VALUE == this.hashCode) {
if (null == this.getCoveragePackageCode()) return super.hashCode();
else {
String hashStr = this.getClass().getName() + ":" + this.getCoveragePackageCode().hashCode();
this.hashCode = hashStr.hashCode();
}
}
return this.hashCode;
}
public String toString () {
return super.toString();
}
}
2) I would like to generate a spring/hibernate/dao structure. This was accomplishable using templates in synchronizer.