|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.statcato.spreadsheet.Cell
public class Cell
A cell in a Spreadsheet
object.
Spreadsheet
Constructor Summary | |
---|---|
Cell(java.lang.String contents,
int row,
int column)
Constructor, given the contents as a string and the row and column of the cell. |
Method Summary | |
---|---|
void |
clear()
Clears the cell contents by setting to the empty string. |
boolean |
equals(Cell cell)
Returns true iff the given cell object is equal to this object. |
int |
getColumn()
Returns the column number of this cell |
java.lang.String |
getContents()
Returns the unformatted string representation the contents of this cell. |
java.lang.Double |
getNumValue()
Returns the numerical value of the cell contents, or null if not a number. |
int |
getRow()
Returns the row number of this cell. |
boolean |
hasData()
Returns true iff this cell is non-empty (the contents is not equal to an empty string). |
boolean |
isNumeric()
Returns true if the cell contents represent a number. |
void |
setColumn(int col)
Sets the column number of the cell. |
void |
setContents(java.lang.String svalue)
Sets the contents to the cell to the specified string. |
void |
setRow(int row)
Sets the row number of the cell. |
java.lang.String |
toString()
Returns the string representation of this cell. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Cell(java.lang.String contents, int row, int column)
contents
- string representation of the cell contentsrow
- row number (integer)column
- column number (integer)Method Detail |
---|
public java.lang.String getContents()
public int getRow()
public int getColumn()
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.Double getNumValue()
public void setContents(java.lang.String svalue)
svalue
- string used to set the cell contentspublic void clear()
public void setRow(int row)
row
- row numberpublic void setColumn(int col)
col
- column numberpublic boolean equals(Cell cell)
cell
- the Cell
object to be compared to this object
public boolean isNumeric()
public boolean hasData()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |