bpiwowar.argparser.utils
Class TreeMapArray<K,V>
java.lang.Object
java.util.AbstractMap<K,V>
java.util.TreeMap<K,ArrayList<V>>
bpiwowar.argparser.utils.TreeMapArray<K,V>
- Type Parameters:
K
- V
-
- All Implemented Interfaces:
- Serializable, Cloneable, Map<K,ArrayList<V>>, NavigableMap<K,ArrayList<V>>, SortedMap<K,ArrayList<V>>
public class TreeMapArray<K,V>
- extends TreeMap<K,ArrayList<V>>
A TreeMap where a value is an ArrayList of a given type
- Author:
- Benjamin Piwowarski
- See Also:
- Serialized Form
Methods inherited from class java.util.TreeMap |
ceilingEntry, ceilingKey, clear, clone, comparator, containsKey, containsValue, descendingKeySet, descendingMap, entrySet, firstEntry, firstKey, floorEntry, floorKey, get, headMap, headMap, higherEntry, higherKey, keySet, lastEntry, lastKey, lowerEntry, lowerKey, navigableKeySet, pollFirstEntry, pollLastEntry, put, putAll, remove, size, subMap, subMap, tailMap, tailMap, values |
TreeMapArray
public TreeMapArray()
TreeMapArray
public TreeMapArray(Comparator<? super K> c)
TreeMapArray
public TreeMapArray(Map<? extends K,? extends ArrayList<V>> m)
TreeMapArray
public TreeMapArray(SortedMap<K,? extends ArrayList<V>> m)
add
public void add(K key,
V value)
- Add a new value to the array list for a given key
- Parameters:
key
- value
-
newInstance
public static <K,V> TreeMapArray<K,V> newInstance()
newInstance
public static <K,V> TreeMapArray<K,V> newInstance(Comparator<? super K> comparator)
addAll
public void addAll(K key,
Collection<? extends V> values)
Copyright © 2013. All Rights Reserved.