public static class TreeComboUtils.TreeModelToComboBoxModelAdapter
extends javax.swing.AbstractListModel
implements javax.swing.ComboBoxModel, javax.swing.event.TreeModelListener
Constructor and Description |
---|
TreeModelToComboBoxModelAdapter(javax.swing.tree.TreeModel aTreeModel) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getElementAt(int index) |
javax.swing.tree.DefaultMutableTreeNode |
getNode(int index) |
javax.swing.tree.DefaultMutableTreeNode |
getNode(java.lang.Object anObject) |
java.lang.Object |
getSelectedItem() |
int |
getSize() |
void |
setSelectedItem(java.lang.Object anObject) |
void |
treeNodesChanged(javax.swing.event.TreeModelEvent e) |
void |
treeNodesInserted(javax.swing.event.TreeModelEvent e) |
void |
treeNodesRemoved(javax.swing.event.TreeModelEvent e) |
void |
treeStructureChanged(javax.swing.event.TreeModelEvent e) |
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListener
public TreeModelToComboBoxModelAdapter(javax.swing.tree.TreeModel aTreeModel)
public void setSelectedItem(java.lang.Object anObject)
setSelectedItem
in interface javax.swing.ComboBoxModel
public java.lang.Object getSelectedItem()
getSelectedItem
in interface javax.swing.ComboBoxModel
public int getSize()
getSize
in interface javax.swing.ListModel
public java.lang.Object getElementAt(int index)
getElementAt
in interface javax.swing.ListModel
public javax.swing.tree.DefaultMutableTreeNode getNode(int index)
public javax.swing.tree.DefaultMutableTreeNode getNode(java.lang.Object anObject)
public void treeNodesChanged(javax.swing.event.TreeModelEvent e)
treeNodesChanged
in interface javax.swing.event.TreeModelListener
public void treeNodesInserted(javax.swing.event.TreeModelEvent e)
treeNodesInserted
in interface javax.swing.event.TreeModelListener
public void treeNodesRemoved(javax.swing.event.TreeModelEvent e)
treeNodesRemoved
in interface javax.swing.event.TreeModelListener
public void treeStructureChanged(javax.swing.event.TreeModelEvent e)
treeStructureChanged
in interface javax.swing.event.TreeModelListener