|
swingx Version 2009-07-31 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TreeTableModel
The model used by JXTreeTable
.
This model is a combination of TreeModel
and
TableModel
for use with the tree table. It does not
actually extends TableModel
, but instead copies method signature as
appropriate and alters other to work with the underlying TreeModel
.
TreeModel
,
TableModel
Method Summary | |
---|---|
Class<?> |
getColumnClass(int columnIndex)
Returns the most specific superclass for all the cell values in the column. |
int |
getColumnCount()
Returns the number of columns in the model. |
String |
getColumnName(int column)
Returns the name of the column at columnIndex . |
int |
getHierarchicalColumn()
Returns the column that is the "tree" column. |
Object |
getValueAt(Object node,
int column)
Returns the value for the node at columnIndex . |
boolean |
isCellEditable(Object node,
int column)
Returns true if the cell for the node at columnIndex is
editable. |
void |
setValueAt(Object value,
Object node,
int column)
Sets the value for the node at columnIndex to
value . |
Methods inherited from interface javax.swing.tree.TreeModel |
---|
addTreeModelListener, getChild, getChildCount, getIndexOfChild, getRoot, isLeaf, removeTreeModelListener, valueForPathChanged |
Method Detail |
---|
Class<?> getColumnClass(int columnIndex)
JXTreeTable
to set up a default
renderer and editor for the column.
columnIndex
- the index of the column
TableModel.getColumnClass(int)
int getColumnCount()
JXTreeTable
uses
this method to determine how many columns it should create and display by
default.
TableModel.getColumnCount()
String getColumnName(int column)
columnIndex
. This is used to
initialize the table's column header name. Note: this name does not need
to be unique; two columns in a table can have the same name.
column
- the index of the column
TableModel.getColumnName(int)
int getHierarchicalColumn()
Object getValueAt(Object node, int column)
node
at columnIndex
. The
node
must be managed by this model. Unamanaged nodes should throw
an IllegalArgumentException
.
node
- the node whose value is to be queriedcolumn
- the column whose value is to be queried
IllegalArgumentException
- if node
is not managed by this model.setValueAt(java.lang.Object, java.lang.Object, int)
,
TableModel.getValueAt(int, int)
boolean isCellEditable(Object node, int column)
node
at columnIndex
is
editable. Otherwise, setValueAt
on the cell will not change the
value of that cell. The node
must be managed by this model.
Unamanaged nodes should throw an IllegalArgumentException
.
node
- the node whose value to be queriedcolumn
- the column whose value to be queried
IllegalArgumentException
- if node
is not managed by this model.setValueAt(java.lang.Object, java.lang.Object, int)
,
TableModel.isCellEditable(int, int)
void setValueAt(Object value, Object node, int column)
node
at columnIndex
to
value
. The node
must be managed by this model.
Unamanaged nodes should throw an IllegalArgumentException
.
value
- the new valuenode
- the node whose value is to be changedcolumn
- the column whose value is to be changed
IllegalArgumentException
- if node
is not managed by this model.getValueAt(java.lang.Object, int)
,
isCellEditable(java.lang.Object, int)
,
TableModel.setValueAt(Object, int, int)
|
swingx Version 2009-07-31 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |