Save This Page
Home » jexcelapi_2_6_8 » jxl.write » [javadoc | source]
jxl.write
public class: DateTime [javadoc | source]
java.lang.Object
   jxl.biff.RecordData
      jxl.biff.WritableRecordData
         jxl.write.biff.CellValue
            jxl.write.biff.DateRecord
               jxl.write.DateTime

All Implemented Interfaces:
    WritableCell, DateCell, ByteData

A Date which may be created on the fly by a user application and added to a spreadsheet NOTE: By default, all dates will have local timezone information added to their UTC value. If this is not desired (eg. if the date entered represents an interval eg. 9.83s for the 100m world record, then use the overloaded constructor which indicate that the date passed in was created under the GMT timezone. It is important that when the date was created, an instruction like Calendar.setTimeZone(TimeZone.getTimeZone("GMT")) was made prior to that
Field Summary
public static final  GMTDate GMT    Instance variable for dummy variable overload 
Fields inherited from jxl.write.biff.DateRecord:
defaultDateFormat
Fields inherited from jxl.biff.WritableRecordData:
maxRecordLength
Constructor:
 public DateTime(DateCell dc) 
    A constructor called by the worksheet when creating a writable version of a spreadsheet that has been read in
    Parameters:
    dc - the date to copy
 public DateTime(int c,
    int r,
    Date d) 
    Constructor
    Parameters:
    c - the column
    r - the row
    d - the date
 protected DateTime(int col,
    int row,
    DateTime dt) 
    Copy constructor used for deep copying
    Parameters:
    col - the column
    row - the row
    dt - the date to copy
 public DateTime(int c,
    int r,
    Date d,
    GMTDate a) 
    Constructor, which adjusts the specified date to take timezone considerations into account
    Parameters:
    c - the column
    r - the row
    d - the date
    a - dummy overload
 public DateTime(int c,
    int r,
    Date d,
    CellFormat st) 
    Constructor which takes the format for this cell
    Parameters:
    c - the column
    r - the row
    st - the format
    d - the date
 public DateTime(int c,
    int r,
    Date d,
    CellFormat st,
    GMTDate a) 
    Constructor, which adjusts the specified date to take timezone considerations into account
    Parameters:
    c - the column
    r - the row
    d - the date
    st - the cell format
    a - the cummy overload
 public DateTime(int c,
    int r,
    Date d,
    CellFormat st,
    boolean tim) 
    Constructor which takes the format for the cell and an indicator as to whether this cell is a full date time or purely just a time eg. if the spreadsheet is to contain the world record for 100m, then the value would be 9.83s, which would be indicated as just a time
    Parameters:
    c - the column
    r - the row
    st - the style
    tim - flag indicating that this represents a time
    d - the date
Method from jxl.write.DateTime Summary:
copyTo,   setDate,   setDate
Methods from jxl.write.biff.DateRecord:
getContents,   getData,   getDate,   getDateFormat,   getType,   isTime,   setDate,   setDate
Methods from jxl.write.biff.CellValue:
addCellFeatures,   columnInserted,   columnRemoved,   decrementColumn,   decrementRow,   getCellFeatures,   getCellFormat,   getColumn,   getData,   getRow,   getSheet,   getWritableCellFeatures,   getXFIndex,   incrementColumn,   incrementRow,   isHidden,   isReferenced,   removeCellFeatures,   removeComment,   removeDataValidation,   rowInserted,   rowRemoved,   setCellDetails,   setCellFeatures,   setCellFormat,   setCopied
Methods from jxl.biff.WritableRecordData:
getBytes,   getData
Methods from jxl.biff.RecordData:
getCode,   getRecord
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from jxl.write.DateTime Detail:
 public WritableCell copyTo(int col,
    int row) 
    Implementation of the deep copy function
 public  void setDate(Date d) 
    Sets the date for this cell
 public  void setDate(Date d,
    GMTDate a) 
    Sets the date for this cell, performing the necessary timezone adjustments