|
Version: 1.1.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JTable org.biomoby.service.dashboard.treetable.JTreeTable
public class JTreeTable
This example shows how to create a simple JTreeTable component, by using a JTree as a renderer (and editor) for the cells in a particular column in the JTable.
Inspired by http://java.sun.com/products/jfc/tsc/articles/treetable1/index.html.
Nested Class Summary | |
---|---|
class |
JTreeTable.TreeTableCellEditor
TreeTableCellEditor implementation. |
class |
JTreeTable.TreeTableCellRenderer
A TreeCellRenderer that displays a JTree. |
Nested classes/interfaces inherited from class javax.swing.JTable |
---|
JTable.DropLocation, JTable.PrintMode |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.BaselineResizeBehavior |
Field Summary |
---|
Fields inherited from class javax.swing.JTable |
---|
AUTO_RESIZE_ALL_COLUMNS, AUTO_RESIZE_LAST_COLUMN, AUTO_RESIZE_NEXT_COLUMN, AUTO_RESIZE_OFF, AUTO_RESIZE_SUBSEQUENT_COLUMNS |
Fields inherited from class javax.swing.JComponent |
---|
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
JTreeTable(TreeTableModel treeTableModel)
A default constructor. |
Method Summary | |
---|---|
int |
getEditingRow()
|
TreeTableModel |
getInnerModel()
Returns the model that has been passed to this table in its constructor. |
JTree |
getTree()
Returns the tree that is being shared between the model. |
JScrollPane |
scrollable()
Put this table in a scrollable pane. |
void |
setRowHeight(int rowHeight)
Overridden to pass the new rowHeight to the tree. |
void |
updateUI()
Overridden to message super and forward the method to the tree. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public JTreeTable(TreeTableModel treeTableModel)
Method Detail |
---|
public JScrollPane scrollable()
public void updateUI()
updateUI
in class JTable
public int getEditingRow()
getEditingRow
in class JTable
public void setRowHeight(int rowHeight)
setRowHeight
in class JTable
public JTree getTree()
public TreeTableModel getInnerModel()
|
Version: 1.1.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |