public boolean equals(Object obj) {
   if (obj == null) return false;
   if (!(obj instanceof AttendanceHistoryDialogParamsVo)) return false;
   AttendanceHistoryDialogParamsVo compareObj = (AttendanceHistoryDialogParamsVo) obj;
   if (this.getPatientRefVo() == null && compareObj.getPatientRefVo() != null) return false;
   if (this.getPatientRefVo() != null && compareObj.getPatientRefVo() == null) return false;
   if (this.getPatientRefVo() != null && compareObj.getPatientRefVo() != null)
     return this.getPatientRefVo().equals(compareObj.getPatientRefVo());
   return super.equals(obj);
 }
 public int compareTo(Object obj, boolean caseInsensitive) {
   if (obj == null) {
     return -1;
   }
   if (caseInsensitive) ; // this is to avoid eclipse warning only.
   if (!(AttendanceHistoryDialogParamsVo.class.isAssignableFrom(obj.getClass()))) {
     throw new ClassCastException(
         "A AttendanceHistoryDialogParamsVo object cannot be compared an Object of type "
             + obj.getClass().getName());
   }
   AttendanceHistoryDialogParamsVo compareObj = (AttendanceHistoryDialogParamsVo) obj;
   int retVal = 0;
   if (retVal == 0) {
     if (this.getPatientRefVo() == null && compareObj.getPatientRefVo() != null) return -1;
     if (this.getPatientRefVo() != null && compareObj.getPatientRefVo() == null) return 1;
     if (this.getPatientRefVo() != null && compareObj.getPatientRefVo() != null)
       retVal = this.getPatientRefVo().compareTo(compareObj.getPatientRefVo());
   }
   return retVal;
 }