public boolean equals(Object obj) {
    if (obj == null) {
      return false;
    }

    CdsPerformanceAppraisalSlotComments cdsPerformanceAppraisalSlotComments = null;

    try {
      cdsPerformanceAppraisalSlotComments = (CdsPerformanceAppraisalSlotComments) obj;
    } catch (ClassCastException cce) {
      return false;
    }

    Integer pk = cdsPerformanceAppraisalSlotComments.getPrimaryKey();

    if (getPrimaryKey().equals(pk)) {
      return true;
    } else {
      return false;
    }
  }
  public int compareTo(CdsPerformanceAppraisalSlotComments cdsPerformanceAppraisalSlotComments) {
    Integer pk = cdsPerformanceAppraisalSlotComments.getPrimaryKey();

    return getPrimaryKey().compareTo(pk);
  }