APIdia Launch Partner
Top Description Fields Constructors Methods
sun.jvm.hotspot.ui.treetable

public Class SimpleTreeTableModel

extends SimpleTreeModel
implements TreeTableModel
Class Inheritance
All Implemented Interfaces
sun.jvm.hotspot.ui.treetable.TreeTableModel, javax.swing.tree.TreeModel
Imports
javax.swing.tree.*, sun.jvm.hotspot.ui.tree.*

An extension of SimpleTreeModel which implements the TreeTableModel interface. It supports a two-column "Name, Value" interface and disabling of editing of the "Value" column. Because of a bug in the implementation of JTreeTable, it always returns "true" for isCellEditable of cells in the "Name" column; otherwise, mouse clicks to open handles are not dispatched properly. Users are responsible for calling setTreeEditable(false) on the JTreeTable to make the names uneditable.

Field Summary

Modifier and TypeField and Description
private boolean

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Class<T>
getColumnClass(int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnClass.

Returns the type for column number column.

public int
getColumnCount()

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnCount.

Returns the number of available columns.

public String
getColumnName(int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnName.

Returns the name for column number column.

public Object
getValueAt(Object node, int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getValueAt.

Returns the value to be displayed for node node, at column number column.

public boolean
getValuesEditable()

Defaults to true

public boolean
isCellEditable(Object node, int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.isCellEditable.

Indicates whether the value for node node, at column number column is editable.

public void
setValueAt(Object aValue, Object node, int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.setValueAt.

Sets the value for node node, at column number column.

public void
setValuesEditable(boolean val)

Defaults to true

Inherited from sun.jvm.hotspot.ui.tree.SimpleTreeModel:
addTreeModelListenerfireTreeStructureChangedgetChildgetChildCountgetIndexOfChildgetRootisLeafremoveTreeModelListenersetRootvalueForPathChanged

Field Detail

valuesEditableback to summary
private boolean valuesEditable

Constructor Detail

SimpleTreeTableModelback to summary
public SimpleTreeTableModel()

Method Detail

getColumnClassback to summary
public Class<T> getColumnClass(int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnClass.

Doc from sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnClass.

Returns the type for column number column.

getColumnCountback to summary
public int getColumnCount()

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnCount.

Doc from sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnCount.

Returns the number of available columns.

getColumnNameback to summary
public String getColumnName(int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnName.

Doc from sun.jvm.hotspot.ui.treetable.TreeTableModel.getColumnName.

Returns the name for column number column.

getValueAtback to summary
public Object getValueAt(Object node, int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.getValueAt.

Doc from sun.jvm.hotspot.ui.treetable.TreeTableModel.getValueAt.

Returns the value to be displayed for node node, at column number column.

getValuesEditableback to summary
public boolean getValuesEditable()

Defaults to true

isCellEditableback to summary
public boolean isCellEditable(Object node, int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.isCellEditable.

Doc from sun.jvm.hotspot.ui.treetable.TreeTableModel.isCellEditable.

Indicates whether the value for node node, at column number column is editable.

setValueAtback to summary
public void setValueAt(Object aValue, Object node, int column)

Implements sun.jvm.hotspot.ui.treetable.TreeTableModel.setValueAt.

Doc from sun.jvm.hotspot.ui.treetable.TreeTableModel.setValueAt.

Sets the value for node node, at column number column.

setValuesEditableback to summary
public void setValuesEditable(boolean val)

Defaults to true