- java.lang.Object
-
- java.util.AbstractMap<String,T>
-
- com.iamsoft.util.ui.swing.nameditem.NamedItemModel<T>
-
- Type Parameters:
T- Type of element stored in model.
@Deprecated public class NamedItemModel<T> extends AbstractMap<String,T> implements ListModel<Map.Entry<String,T>>, SortedMap<String,T>
Deprecated.Deprecated.Map linking key and some immutable object. Allows clients to listen for updates, additions and removals. Note that submaps will not fire events originating in the primary map. Renaming a key will trigger an add and a remove list event and a single update event. Change events are useful for propagating updates to existing dependents. List data events guaranteed to be fired before update events.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object,V extends Object>
-
-
Constructor Summary
Constructors Constructor Description NamedItemModel()Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaddListDataListener(ListDataListener pListener)Deprecated.voidaddUpdateListener(UpdateListener<? super T> pListener)Deprecated.Comparator<? super String>comparator()Deprecated.TreeEntrySet<String,T>entrySet()Deprecated.StringfirstKey()Deprecated.Map.Entry<String,T>getElementAt(int pIdx)Deprecated.intgetSize()Deprecated.NamedItemModel<T>headMap(String pToKey)Deprecated.NavigableSet<String>keySet()Deprecated.StringlastKey()Deprecated.Tput(String pKey, T pVal)Deprecated.Add/replace element and fire events.voidremoveListDataListener(ListDataListener pListener)Deprecated.voidremoveUpdateListener(UpdateListener<? super T> pListener)Deprecated.voidrenameKey(String pOldVal, String pNewVal)Deprecated.Update entry key.NamedItemModel<T>subMap(String pFromKey, String pToKey)Deprecated.NamedItemModel<T>tailMap(String pFromKey)Deprecated.-
Methods inherited from class java.util.AbstractMap
clear, clone, containsKey, containsValue, equals, get, hashCode, isEmpty, putAll, remove, size, toString, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, equals, forEach, get, getOrDefault, hashCode, isEmpty, merge, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size
-
-
-
-
Method Detail
-
addListDataListener
public void addListDataListener(ListDataListener pListener)
Deprecated.- Specified by:
addListDataListenerin interfaceListModel<T>
-
removeListDataListener
public void removeListDataListener(ListDataListener pListener)
Deprecated.- Specified by:
removeListDataListenerin interfaceListModel<T>
-
addUpdateListener
public void addUpdateListener(UpdateListener<? super T> pListener)
Deprecated.
-
removeUpdateListener
public void removeUpdateListener(UpdateListener<? super T> pListener)
Deprecated.
-
renameKey
public void renameKey(String pOldVal, String pNewVal)
Deprecated.Update entry key. This method will trigger an update event rather than a removal followed by an addition.- Parameters:
pOldVal- Original key value.pNewVal- New key value.- Throws:
NoSuchElementException- If new key exists or old key does not.
-
entrySet
public TreeEntrySet<String,T> entrySet()
Deprecated.
-
comparator
public Comparator<? super String> comparator()
Deprecated.- Specified by:
comparatorin interfaceSortedMap<String,T>
-
firstKey
public String firstKey()
Deprecated.
-
keySet
public NavigableSet<String> keySet()
Deprecated.
-
headMap
public NamedItemModel<T> headMap(String pToKey)
Deprecated.
-
tailMap
public NamedItemModel<T> tailMap(String pFromKey)
Deprecated.
-
subMap
public NamedItemModel<T> subMap(String pFromKey, String pToKey)
Deprecated.
-
getElementAt
public Map.Entry<String,T> getElementAt(int pIdx)
Deprecated.- Specified by:
getElementAtin interfaceListModel<T>
-
-