Package org.apache.poi.ss.usermodel
Class CellValue
- java.lang.Object
-
- org.apache.poi.ss.usermodel.CellValue
-
public final class CellValue extends Object
Mimics the 'data view' of a cell. This allows formula evaluator to return a CellValue instead of precasting the value to String or Number or boolean type.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
formatAsString()
boolean
getBooleanValue()
CellType
getCellType()
Return the cell type.static CellValue
getError(int errorCode)
byte
getErrorValue()
double
getNumberValue()
String
getStringValue()
String
toString()
static CellValue
valueOf(boolean booleanValue)
-
-
-
Constructor Detail
-
CellValue
public CellValue(double numberValue)
-
CellValue
public CellValue(String stringValue)
-
-
Method Detail
-
valueOf
public static CellValue valueOf(boolean booleanValue)
-
getError
public static CellValue getError(int errorCode)
-
getBooleanValue
public boolean getBooleanValue()
- Returns:
- Returns the booleanValue.
-
getNumberValue
public double getNumberValue()
- Returns:
- Returns the numberValue.
-
getStringValue
public String getStringValue()
- Returns:
- Returns the stringValue.
-
getCellType
public CellType getCellType()
Return the cell type.- Returns:
- the cell type
-
getErrorValue
public byte getErrorValue()
- Returns:
- Returns the errorValue.
-
formatAsString
public String formatAsString()
-
-