/**
   * Sees if the extended formatting record at the specified position represents a date. First
   * checks against the built in formats, and then checks against the hash map of FormatRecords
   *
   * @param pos the xf format index
   * @return TRUE if this format index is formatted as a Date
   */
  public final boolean isDate(int pos) {
    XFRecord xfr = (XFRecord) xfRecords.get(pos);

    if (xfr.isDate()) {
      return true;
    }

    FormatRecord fr = (FormatRecord) formats.get(new Integer(xfr.getFormatRecord()));

    return fr == null ? false : fr.isDate();
  }
  /**
   * Gets the DateFormat used to format the cell.
   *
   * @param pos the xf format index
   * @return the DateFormat object used to format the date in the original excel cell
   */
  public final DateFormat getDateFormat(int pos) {
    XFRecord xfr = (XFRecord) xfRecords.get(pos);

    if (xfr.isDate()) {
      return xfr.getDateFormat();
    }

    FormatRecord fr = (FormatRecord) formats.get(new Integer(xfr.getFormatRecord()));

    if (fr == null) {
      return null;
    }

    return fr.isDate() ? fr.getDateFormat() : null;
  }