jxl.write.biff
Class ReadFormulaRecord

java.lang.Object
  |
  +--jxl.biff.RecordData
        |
        +--jxl.biff.WritableRecordData
              |
              +--jxl.write.biff.CellValue
                    |
                    +--jxl.write.biff.ReadFormulaRecord
All Implemented Interfaces:
ByteData, Cell, FormulaData, WritableCell

class ReadFormulaRecord
extends CellValue
implements FormulaData

A formula record. This is invoked when copying a formula from a read only spreadsheet This method implements the FormulaData interface to allow the copying of writable sheets


Field Summary
private  FormulaData formula
          The underlying formula from the read sheet
 
Fields inherited from class jxl.write.biff.CellValue
column, format, formattingRecords, referenced, row, sheet
 
Fields inherited from class jxl.biff.RecordData
code, record
 
Constructor Summary
ReadFormulaRecord(FormulaData f)
          Constructor
 
Method Summary
 java.lang.String getContents()
          Quick and dirty function to return the contents of this cell as a string.
 byte[] getData()
          Gets the binary data for output to file
 byte[] getFormulaData()
          Gets the raw bytes for the formula.
 CellType getType()
          Returns the content type of this cell
 
Methods inherited from class jxl.write.biff.CellValue
decrementColumn, decrementRow, getCellFormat, getColumn, getRow, getXFIndex, incrementColumn, incrementRow, isHidden, isReferenced, setCellDetails, setCellFormat
 
Methods inherited from class jxl.biff.WritableRecordData
getBytes
 
Methods inherited from class jxl.biff.RecordData
getCode, getRecord
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 
Methods inherited from interface jxl.Cell
getCellFormat, getColumn, getRow, isHidden
 

Field Detail

formula

private FormulaData formula
The underlying formula from the read sheet
Constructor Detail

ReadFormulaRecord

public ReadFormulaRecord(FormulaData f)
Constructor
Parameters:
f - the formula to copy
Method Detail

getData

public byte[] getData()
Gets the binary data for output to file
Overrides:
getData in class CellValue
Returns:
the binary data

getType

public CellType getType()
Returns the content type of this cell
Specified by:
getType in interface Cell
Returns:
the content type for this cell

getContents

public java.lang.String getContents()
Quick and dirty function to return the contents of this cell as a string. For more complex manipulation of the contents, it is necessary to cast this interface to correct subinterface
Specified by:
getContents in interface Cell
Returns:
the contents of this cell as a string

getFormulaData

public byte[] getFormulaData()
                      throws FormulaException
Gets the raw bytes for the formula. This will include the parsed tokens array. Used when copying spreadsheets
Specified by:
getFormulaData in interface FormulaData
Returns:
the raw record data