Package editor
Class PopupListModel
- java.lang.Object
-
- javax.swing.AbstractListModel
-
- editor.PopupListModel
-
- All Implemented Interfaces:
IIntelliTextModel
,Serializable
,ListModel
public abstract class PopupListModel extends AbstractListModel implements IIntelliTextModel
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class javax.swing.AbstractListModel
listenerList
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
PopupListModel()
protected
PopupListModel(Predicate filter)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract PopupListModel
createSubset(List subset)
Given the a subset of components in this model, creates a new model containing just this subset.Object
getElementAt(int iIndex)
Predicate
getFilter()
IIntelliTextModel
getFilteredModel(String strPrefix)
String
getFilterPrefix()
abstract List
getModel()
Returns the underlying list.List
getModelUpdatedOrFilteredByPredicate()
Returns the underlying list, filtered by the predicate if it existsint
getSize()
abstract List
getUnfilteredModel()
Returns an unfiltered version of this model.void
setFilter(Predicate filter)
-
Methods inherited from class javax.swing.AbstractListModel
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListener
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface editor.IIntelliTextModel
getDisplayText, getInsertionTextFrom, getTypeName, parseElement
-
-
-
-
Constructor Detail
-
PopupListModel
protected PopupListModel()
-
PopupListModel
protected PopupListModel(Predicate filter)
-
-
Method Detail
-
createSubset
public abstract PopupListModel createSubset(List subset)
Given the a subset of components in this model, creates a new model containing just this subset.
-
getModel
public abstract List getModel()
Returns the underlying list.
-
getUnfilteredModel
public abstract List getUnfilteredModel()
Returns an unfiltered version of this model. If the model is not filtered, this may return the same reference as getModel().
-
setFilter
public void setFilter(Predicate filter)
-
getFilter
public Predicate getFilter()
-
getElementAt
public Object getElementAt(int iIndex)
- Specified by:
getElementAt
in interfaceListModel
-
getFilterPrefix
public String getFilterPrefix()
- Specified by:
getFilterPrefix
in interfaceIIntelliTextModel
-
getFilteredModel
public IIntelliTextModel getFilteredModel(String strPrefix)
- Specified by:
getFilteredModel
in interfaceIIntelliTextModel
-
getModelUpdatedOrFilteredByPredicate
public List getModelUpdatedOrFilteredByPredicate()
Returns the underlying list, filtered by the predicate if it exists
-
-