Package jadex.collection
Class IndexMap.ListIndexMap<K,V>
java.lang.Object
jadex.collection.IndexMap<K,V>
jadex.collection.IndexMap.ListIndexMap<K,V>
- All Implemented Interfaces:
Serializable
,Cloneable
,Iterable<V>
,Collection<V>
,List<V>
,SequencedCollection<V>
Provide access to the index map via list interface.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class jadex.collection.IndexMap
IndexMap.ListIndexMap<K,
V>, IndexMap.MapIndexMap<K, V> -
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a new list interface index map.Create a new list interface index map. -
Method Summary
Methods inherited from class jadex.collection.IndexMap
add, add, add, add, addAll, addAll, clear, contains, containsAll, containsKey, containsValue, entrySet, equals, get, get, getAsList, getAsMap, getKey, getKeys, getKeys, getObjects, getObjects, hashCode, indexOf, isEmpty, iterator, keySet, lastIndexOf, listIterator, listIterator, put, putAll, remove, removeAll, removeKey, removeValue, replace, retainAll, set, size, subList, toArray, toArray, toString, values
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
Methods inherited from interface java.util.List
add, add, addAll, addAll, addFirst, addLast, clear, contains, containsAll, equals, get, getFirst, getLast, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, removeAll, removeFirst, removeLast, replaceAll, retainAll, reversed, set, size, sort, spliterator, subList, toArray, toArray
-
Constructor Details
-
ListIndexMap
public ListIndexMap()Create a new list interface index map. -
ListIndexMap
Create a new list interface index map.- Parameters:
list
- The list.map
- The map.
-
-
Method Details
-
remove
Removes the first occurrence in this list of the specified element. If this list does not contain the element, it is unchanged. More formally, removes the element with the lowest index i such that (o==null ? get(i)==null : o.equals(get(i))) (if such an element exists).- Specified by:
remove
in interfaceCollection<K>
- Specified by:
remove
in interfaceList<K>
- Parameters:
o
- element to be removed from this list, if present.- Returns:
- true if this list contained the specified element.
- Throws:
ClassCastException
- if the type of the specified element is incompatible with this list (optional).NullPointerException
- if the specified element is null and this list does not support null elements (optional).
-
clone
Clone an index map.
-