poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject svn commit: r781624 - /poi/trunk/src/java/org/apache/poi/ss/usermodel/Cell.java
Date Thu, 04 Jun 2009 00:08:34 GMT
Author: josh
Date: Thu Jun  4 00:08:33 2009
New Revision: 781624

URL: http://svn.apache.org/viewvc?rev=781624&view=rev
Log:
Fix for javadoc error in Cell.setCellValue(Date) found by Mike Curwen

Modified:
    poi/trunk/src/java/org/apache/poi/ss/usermodel/Cell.java

Modified: poi/trunk/src/java/org/apache/poi/ss/usermodel/Cell.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/ss/usermodel/Cell.java?rev=781624&r1=781623&r2=781624&view=diff
==============================================================================
--- poi/trunk/src/java/org/apache/poi/ss/usermodel/Cell.java (original)
+++ poi/trunk/src/java/org/apache/poi/ss/usermodel/Cell.java Thu Jun  4 00:08:33 2009
@@ -149,11 +149,19 @@
     void setCellValue(double value);
 
     /**
-     * Set a boolean value for the cell
-     *
-     * @param value the boolean value to set this cell to.  For formulas we'll set the
-     *        precalculated value, for booleans we'll set its value. For other types we
-     *        will change the cell to a boolean cell and set its value.
+     * Converts the supplied date to its equivalent Excel numeric value and sets
+     * that into the cell.
+     * <p/>
+     * <b>Note</b> - There is actually no 'DATE' cell type in Excel. In many
+     * cases (when entering date values), Excel automatically adjusts the
+     * <i>cell style</i> to some date format, creating the illusion that the
cell
+     * data type is now something besides {@link Cell#CELL_TYPE_NUMERIC}.  POI
+     * does not attempt to replicate this behaviour.  To make a numeric cell
+     * display as a date, use {@link #setCellStyle(CellStyle)} etc.
+     * 
+     * @param value the numeric value to set this cell to.  For formulas we'll set the
+     *        precalculated value, for numerics we'll set its value. For other types we
+     *        will change the cell to a numerics cell and set its value.
      */
     void setCellValue(Date value);
 



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org


Mime
View raw message