Package diva.gui.toolbox
Class ListDataModel
- java.lang.Object
-
- javax.swing.AbstractListModel<E>
-
- javax.swing.DefaultComboBoxModel
-
- diva.gui.toolbox.ListDataModel
-
- All Implemented Interfaces:
java.io.Serializable
,javax.swing.ComboBoxModel
,javax.swing.ListModel
,javax.swing.MutableComboBoxModel
public class ListDataModel extends javax.swing.DefaultComboBoxModel
A model that captures the notion of a list of elements with a single selected element. This is really just a DefaultComboBoxModel, because that class happens to fit our requirements. We subclass DefaultComboBoxModel so we can modify it if any of the behavior should not be quite right.- Version:
- $Id$
- Author:
- John Reekie
- See Also:
- Serialized Form
- Pt.AcceptedRating:
- Red
-
-
Constructor Summary
Constructors Constructor Description ListDataModel()
Create a new model.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
contains(java.lang.Object o)
Return whether or not the given item is contained by the modeljava.util.List
getList()
Return this model as a list.java.util.Iterator
iterator()
Return an iterator over the elements in the model.-
Methods inherited from class javax.swing.DefaultComboBoxModel
addAll, addAll, addElement, getElementAt, getIndexOf, getSelectedItem, getSize, insertElementAt, removeAllElements, removeElement, removeElementAt, setSelectedItem
-
Methods inherited from class javax.swing.AbstractListModel
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListener
-
-