|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectedu.psu.geovista.app.spreadsheet.formula.Cell
| Field Summary | |
static int |
NULL
Value Type |
static int |
NUMBER
The integer code that denotes the cell holds numbers. |
static int |
TEXT
The integer code that denotes the cell holds text. |
static int |
UNKNOWN
The integer code that denotes the cell holds a edu.psu.geovista.app.spreadsheet.formula. |
| Constructor Summary | |
Cell(java.util.Vector _container,
SSTableModel tm)
This constructor constructs a cell that will not have cells referencing it and are not formulas. |
|
| Method Summary | |
boolean |
addOwner(Cell cell)
protect against loop reference |
int |
compareTo(Cell x,
boolean ascend)
not finish yet, just for treeset String: if can't convert to number, alway on the top ."" is set to null in cell null<"": alway at the bottom number: always in middle |
void |
evaluate()
|
static java.lang.String |
getAbsCellAddress(java.awt.Point p)
Given a cell's address in View(table) return absolute address in String format |
java.util.Vector |
getContainer()
This method determines a cell is a edu.psu.geovista.app.spreadsheet.formula cell that has a error. |
SSTableModel |
getDataModel()
|
Formula |
getFormula()
This method returns the edu.psu.geovista.app.spreadsheet.formula associated with the cell or null if it does not exist. |
static java.lang.String |
getRelCellAddress(java.awt.Point p)
Given a cell's address in View(table) return relative address in String format |
java.lang.Object |
getValue()
If it is a data cell, it returns the data of the cell. |
int |
getValueType()
This method is useful for determining what information a cell holds. |
java.awt.Point |
getViewAddress()
return the address of the cell in Table in form of (x,y) Need translate. |
java.lang.String |
getViewAddressText()
|
boolean |
isDeleted()
If the column or row contain the cell is deleted, the cell is set "deleted" |
boolean |
isFormula()
This method returns true IFF it is a edu.psu.geovista.app.spreadsheet.formula cell |
void |
setAsFormula(boolean isf)
This method sets the cell to be a edu.psu.geovista.app.spreadsheet.formula cell. |
void |
setDeleted(boolean d)
|
void |
setFormula(Formula form)
|
void |
setValue(java.lang.Object datum)
Sets the value field of the cell. |
void |
setValueType(int t)
|
java.lang.String |
toString()
toString() method return same data as getValue(), but in different format toString() return String format for table.getValue() to paintCell() getValue() return Number for evaluate edu.psu.geovista.app.spreadsheet.formula called when paint cell |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final int NULL
public static final int TEXT
public static final int NUMBER
public static final int UNKNOWN
| Constructor Detail |
public Cell(java.util.Vector _container,
SSTableModel tm)
Warning: Do not use this with Formulas
| Method Detail |
public boolean addOwner(Cell cell)
public void evaluate()
public Formula getFormula()
public void setFormula(Formula form)
public java.lang.Object getValue()
public void setValue(java.lang.Object datum)
datum - the object to set the value of cell topublic void setAsFormula(boolean isf)
public int getValueType()
public void setValueType(int t)
public boolean isFormula()
public boolean isDeleted()
public void setDeleted(boolean d)
public SSTableModel getDataModel()
public java.util.Vector getContainer()
public java.lang.String toString()
public int compareTo(Cell x,
boolean ascend)
public java.awt.Point getViewAddress()
public java.lang.String getViewAddressText()
public static java.lang.String getRelCellAddress(java.awt.Point p)
public static java.lang.String getAbsCellAddress(java.awt.Point p)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||