public class StreamingCell
extends java.lang.Object
implements org.apache.poi.ss.usermodel.Cell
| Constructor and Description |
|---|
StreamingCell(org.apache.poi.ss.usermodel.Sheet sheet,
int columnIndex,
int rowIndex,
boolean use1904Dates) |
StreamingCell(org.apache.poi.ss.usermodel.Sheet sheet,
int columnIndex,
org.apache.poi.ss.usermodel.Row row,
boolean use1904Dates) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.poi.ss.util.CellAddress |
getAddress() |
org.apache.poi.ss.util.CellRangeAddress |
getArrayFormulaRange()
Not supported
|
boolean |
getBooleanCellValue()
Get the value of the cell as a boolean.
|
org.apache.poi.ss.usermodel.CellType |
getCachedFormulaResultType()
Only valid for formula cells
|
org.apache.poi.ss.usermodel.Comment |
getCellComment()
Returns cell comment associated with this cell
|
java.lang.String |
getCellFormula()
Return a formula for the cell, for example,
SUM(C4:E4) |
org.apache.poi.ss.usermodel.CellStyle |
getCellStyle() |
org.apache.poi.ss.usermodel.CellType |
getCellType()
Return the cell type.
|
int |
getColumnIndex()
Returns column index of this cell
|
java.util.Date |
getDateCellValue()
Get the value of the cell as a date.
|
byte |
getErrorCellValue() |
org.apache.poi.ss.usermodel.Hyperlink |
getHyperlink()
Returns hyperlink associated with this cell.
|
java.time.LocalDateTime |
getLocalDateTimeCellValue() |
double |
getNumericCellValue()
Get the value of the cell as a number.
|
java.lang.String |
getNumericFormat() |
org.apache.poi.xssf.usermodel.XSSFRichTextString |
getRichStringCellValue()
Get the value of the cell as a XSSFRichTextString
|
org.apache.poi.ss.usermodel.Row |
getRow()
Row is not guaranteed to be set.
|
int |
getRowIndex()
Returns row index of a row in the sheet that contains this cell
|
org.apache.poi.ss.usermodel.Sheet |
getSheet() |
java.lang.String |
getStringCellValue()
Get the value of the cell as a string.
|
boolean |
isPartOfArrayFormulaGroup()
Not supported
|
void |
removeCellComment()
Update operations are not supported
|
void |
removeFormula()
Update operations are not supported
|
void |
removeHyperlink()
Update operations are not supported
|
void |
setAsActiveCell()
Update operations are not supported
|
void |
setBlank()
Update operations are not supported
|
void |
setCellComment(org.apache.poi.ss.usermodel.Comment comment)
Update operations are not supported
|
void |
setCellErrorValue(byte value)
Update operations are not supported
|
void |
setCellFormula(java.lang.String formula)
Update operations are not supported
|
void |
setCellStyle(org.apache.poi.ss.usermodel.CellStyle cellStyle) |
void |
setCellType(org.apache.poi.ss.usermodel.CellType cellType)
Update operations are not supported
|
void |
setCellValue(boolean value)
Update operations are not supported
|
void |
setCellValue(java.util.Calendar value)
Update operations are not supported
|
void |
setCellValue(java.util.Date value)
Update operations are not supported
|
void |
setCellValue(double value)
Update operations are not supported
|
void |
setCellValue(java.time.LocalDate value)
Update operations are not supported
|
void |
setCellValue(java.time.LocalDateTime value)
Update operations are not supported
|
void |
setCellValue(org.apache.poi.ss.usermodel.RichTextString value)
Update operations are not supported
|
void |
setCellValue(java.lang.String value)
Update operations are not supported
|
void |
setHyperlink(org.apache.poi.ss.usermodel.Hyperlink link)
Update operations are not supported
|
public StreamingCell(org.apache.poi.ss.usermodel.Sheet sheet,
int columnIndex,
int rowIndex,
boolean use1904Dates)
public StreamingCell(org.apache.poi.ss.usermodel.Sheet sheet,
int columnIndex,
org.apache.poi.ss.usermodel.Row row,
boolean use1904Dates)
public java.lang.String getNumericFormat()
public void setCellStyle(org.apache.poi.ss.usermodel.CellStyle cellStyle)
setCellStyle in interface org.apache.poi.ss.usermodel.Cellpublic int getColumnIndex()
getColumnIndex in interface org.apache.poi.ss.usermodel.Cellpublic int getRowIndex()
getRowIndex in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.usermodel.Row getRow()
getRow in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.usermodel.Sheet getSheet()
getSheet in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.usermodel.CellType getCellType()
getCellType in interface org.apache.poi.ss.usermodel.Cellpublic java.lang.String getStringCellValue()
getStringCellValue in interface org.apache.poi.ss.usermodel.Cellpublic double getNumericCellValue()
getNumericCellValue in interface org.apache.poi.ss.usermodel.Celljava.lang.NumberFormatException - if the cell value isn't a parseable double.public java.util.Date getDateCellValue()
getDateCellValue in interface org.apache.poi.ss.usermodel.Celljava.lang.IllegalStateException - if the cell type returned by getCellType() is CELL_TYPE_STRINGjava.lang.NumberFormatException - if the cell value isn't a parseable double.public boolean getBooleanCellValue()
getBooleanCellValue in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.usermodel.CellStyle getCellStyle()
getCellStyle in interface org.apache.poi.ss.usermodel.Cellpublic java.lang.String getCellFormula()
SUM(C4:E4)getCellFormula in interface org.apache.poi.ss.usermodel.Celljava.lang.IllegalStateException - if the cell type returned by getCellType() is not CELL_TYPE_FORMULA or
if the cell has a shared formula that can't be evaluatedpublic org.apache.poi.xssf.usermodel.XSSFRichTextString getRichStringCellValue()
For numeric cells we throw an exception. For blank cells we return an empty string. For formula cells we return the pre-calculated value if a string, otherwise an exception
getRichStringCellValue in interface org.apache.poi.ss.usermodel.CellNotSupportedException - if the cell type is unsupportedpublic org.apache.poi.ss.usermodel.CellType getCachedFormulaResultType()
getCachedFormulaResultType in interface org.apache.poi.ss.usermodel.CellCellType.NUMERIC, CellType.STRING,
CellType.BOOLEAN, CellType.ERROR) depending
on the cached value of the formulajava.lang.IllegalStateException - if cell is not formula typeNotSupportedException - if cell formula type is unknownpublic java.time.LocalDateTime getLocalDateTimeCellValue()
getLocalDateTimeCellValue in interface org.apache.poi.ss.usermodel.Cellpublic byte getErrorCellValue()
getErrorCellValue in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.util.CellAddress getAddress()
getAddress in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.usermodel.Comment getCellComment()
getCellComment in interface org.apache.poi.ss.usermodel.Cellnulljava.lang.IllegalStateException - if StreamingReader.Builder.setReadComments(boolean) is not set to truepublic org.apache.poi.ss.usermodel.Hyperlink getHyperlink()
getHyperlink in interface org.apache.poi.ss.usermodel.Cellnulljava.lang.IllegalStateException - if StreamingReader.Builder.setReadHyperlinks(boolean) is not set to truepublic void setCellType(org.apache.poi.ss.usermodel.CellType cellType)
setCellType in interface org.apache.poi.ss.usermodel.Cellpublic void setBlank()
setBlank in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(double value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(java.util.Date value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(java.util.Calendar value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(java.time.LocalDate value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(java.time.LocalDateTime value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(org.apache.poi.ss.usermodel.RichTextString value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellValue(java.lang.String value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellFormula(java.lang.String formula)
throws org.apache.poi.ss.formula.FormulaParseException
setCellFormula in interface org.apache.poi.ss.usermodel.Cellorg.apache.poi.ss.formula.FormulaParseExceptionpublic void removeFormula()
throws java.lang.IllegalStateException
removeFormula in interface org.apache.poi.ss.usermodel.Celljava.lang.IllegalStateExceptionpublic void setCellValue(boolean value)
setCellValue in interface org.apache.poi.ss.usermodel.Cellpublic void setCellErrorValue(byte value)
setCellErrorValue in interface org.apache.poi.ss.usermodel.Cellpublic void setAsActiveCell()
setAsActiveCell in interface org.apache.poi.ss.usermodel.Cellpublic void setCellComment(org.apache.poi.ss.usermodel.Comment comment)
setCellComment in interface org.apache.poi.ss.usermodel.Cellpublic void removeCellComment()
removeCellComment in interface org.apache.poi.ss.usermodel.Cellpublic void setHyperlink(org.apache.poi.ss.usermodel.Hyperlink link)
setHyperlink in interface org.apache.poi.ss.usermodel.Cellpublic void removeHyperlink()
removeHyperlink in interface org.apache.poi.ss.usermodel.Cellpublic org.apache.poi.ss.util.CellRangeAddress getArrayFormulaRange()
getArrayFormulaRange in interface org.apache.poi.ss.usermodel.Cellpublic boolean isPartOfArrayFormulaGroup()
isPartOfArrayFormulaGroup in interface org.apache.poi.ss.usermodel.Cell