|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.swing.table.AbstractTableModel | +--TransDistanceModel
This class is used to display the transform distance table in the NJ algorithm.
Field Summary |
Fields inherited from class javax.swing.table.AbstractTableModel |
listenerList |
Constructor Summary | |
TransDistanceModel(int numOfNodes,
Node[] nodes,
double[][] inTransDistance,
int random_m,
int random_n)
Construct the object with the specified values. |
Method Summary | |
int |
getColumnCount()
Overrides the method in the TableModel class and returns the column count of the table. |
java.lang.String |
getColumnName(int columnIndex)
Overrides the method in the TableModel class and returns the column names of the table. |
int |
getRowCount()
Overrides the method in the TableModel class and returns the row count of the table. |
java.lang.Object |
getValueAt(int row,
int col)
Overrides the method in the TableModel class and returns the value of each table cell. |
void |
update()
Updates and resets the random question cell row and column. |
Methods inherited from class javax.swing.table.AbstractTableModel |
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TransDistanceModel(int numOfNodes, Node[] nodes, double[][] inTransDistance, int random_m, int random_n)
numOfNodes
- the number of nodes created so farnodes
- the nodes of the treesinTransDistance
- the transform distance matrixrandom_m
- the row index of the cell for pop up questionsrandom_n
- the column index of the cell for pop up questionsMethod Detail |
public int getColumnCount()
public int getRowCount()
public java.lang.Object getValueAt(int row, int col)
row
- the row whose value is to be queriedcol
- the column whose value is to be queried
public java.lang.String getColumnName(int columnIndex)
getColumnName
in interface javax.swing.table.TableModel
getColumnName
in class javax.swing.table.AbstractTableModel
columnIndex
- the index of the column
public void update()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |