wt.clients.units
Class UnitsSelectorModel
java.lang.Object
javax.swing.AbstractListModel
wt.clients.widgets.ListSelectorModel
wt.clients.units.UnitsSelectorModel
- All Implemented Interfaces:
- ListModel, Serializable
- public class UnitsSelectorModel
- extends ListSelectorModel
This is the model for the listSelectorlist. This extends the
AbstractListModel and provides features like setListData,
add, remove, sorted data
- See Also:
- Serialized Form
Methods inherited from class wt.clients.widgets.ListSelectorModel |
capacity, clear, copyInto, elementAt, elements, ensureCapacity, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, firstElement, get, getAllValues, getElementAt, getListenersEnabled, getSize, indexOf, indexOf, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, removeAllElements, removeElement, removeElementAt, removeRange, setListData, setListData, setListenersEnabled, size, toArray, toString, trimToSize |
UnitsSelectorModel
public UnitsSelectorModel()
contains
public boolean contains(Object elem)
- Return true is the list already contains the element
- Overrides:
contains
in class ListSelectorModel
- Returns:
- true if the item is already added to the list
replaceObject
private boolean replaceObject(Object obj,
int index)
addElement
public void addElement(Object obj)
- Adds the element into the list. If it is a string, it is added
to the list in ascending order
- Overrides:
addElement
in class ListSelectorModel