Class BasicIDARECell
- java.lang.Object
-
- idare.imagenode.Interfaces.DataSetReaders.WorkBook.BasicImplementation.BasicIDARECell
-
- All Implemented Interfaces:
IDARECell
public class BasicIDARECell extends Object implements IDARECell
Basic implementation of a Simple Cell for aBasicIDAREWorkbook.- Author:
- Thomas Pfau
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface idare.imagenode.Interfaces.DataSetReaders.WorkBook.IDARECell
IDARECell.CellType
-
-
Constructor Summary
Constructors Constructor Description BasicIDARECell(IDARECell.CellType type, BasicIDARERow containingRow)Basic Constructor indicating the containing row and the type of the cellBasicIDARECell(IDARECell.CellType type, String value, BasicIDARERow containingRow)Basic Constructor indicating the containing row and the type of the cell, along with the value to be stored.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IDARECell.CellTypegetCellType()Get the Cell Type ofintgetColumnIndex()Get the index of the column of this cell.StringgetFormattedCellValue()Get a string representation of the value of this cell (regardless what this cell actually represents).doublegetNumericCellValue()Get the Numeric Value of this cell, if it can be converted to numeric.StringgetStringCellValue()Get the string cell value, if the cell is a string cell.voidsetValue(String value)Set the value (this is unchecked wrt the type defined).
-
-
-
Constructor Detail
-
BasicIDARECell
public BasicIDARECell(IDARECell.CellType type, BasicIDARERow containingRow)
Basic Constructor indicating the containing row and the type of the cell- Parameters:
type- the CellType of the cellcontainingRow- The Row containing this cell
-
BasicIDARECell
public BasicIDARECell(IDARECell.CellType type, String value, BasicIDARERow containingRow)
Basic Constructor indicating the containing row and the type of the cell, along with the value to be stored.- Parameters:
type- the CellType of this cellvalue- the value of this cellcontainingRow- the row containing this cell
-
-
Method Detail
-
getCellType
public IDARECell.CellType getCellType()
Description copied from interface:IDARECellGet the Cell Type of- Specified by:
getCellTypein interfaceIDARECell- Returns:
- the Type of the Cell (defined by the static definitions in
IDARECell
-
getColumnIndex
public int getColumnIndex()
Description copied from interface:IDARECellGet the index of the column of this cell.- Specified by:
getColumnIndexin interfaceIDARECell- Returns:
- the column index
-
getNumericCellValue
public double getNumericCellValue()
Description copied from interface:IDARECellGet the Numeric Value of this cell, if it can be converted to numeric. Can throw exceptions if the contained value is either not a parsable double or the Cell Type is String.- Specified by:
getNumericCellValuein interfaceIDARECell- Returns:
- the numeric value of this cell
-
getStringCellValue
public String getStringCellValue()
Description copied from interface:IDARECellGet the string cell value, if the cell is a string cell. Can throw exceptions if the cell type is numeric.- Specified by:
getStringCellValuein interfaceIDARECell- Returns:
- the string cell value.
-
getFormattedCellValue
public String getFormattedCellValue()
Description copied from interface:IDARECellGet a string representation of the value of this cell (regardless what this cell actually represents).- Specified by:
getFormattedCellValuein interfaceIDARECell- Returns:
- a String representing the value of this cell.
-
setValue
public void setValue(String value)
Set the value (this is unchecked wrt the type defined).- Parameters:
value- the value this Cell should have
-
-