Package eu.simuline.util
Class ListMap.Values
- java.lang.Object
-
- java.util.AbstractCollection<V>
-
- eu.simuline.util.ListMap.Values
-
- All Implemented Interfaces:
Iterable<V>,Collection<V>
private class ListMap.Values extends AbstractCollection<V>
Represents the values collection of the enclosing map given byListMap.values().Like base class
AbstractCollection, this class supports neitherCollection.add(Object)norCollection.addAll(Collection), i.e. those methods throw anUnsupportedOperationException. In contrast, this class supports methodsSet.clear(),Collection.remove(Object),Collection.removeAll(Collection)andCollection.retainAll(Collection). The iterator returned byiterator()supports @link Iterator#remove()}.- See Also:
ListMap.valuesColl
-
-
Constructor Summary
Constructors Modifier Constructor Description privateValues()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()Clears actually the enclosingListMapdelegating toListMap.clear().booleancontains(Object obj)Returns actually whetherobjis a value of the enclosingListMapdelegating toListMap.containsValue(Object).Iterator<V>iterator()Returns actually an instance ofListMap.ValuesIterator.booleanremove(Object obj)Interpretesobjas value of the enclosingListMapand removes the first according key-value pair if present.intsize()Returns actually the size of the enclosingListMapdelegating toListMap.size().-
Methods inherited from class java.util.AbstractCollection
add, addAll, containsAll, isEmpty, removeAll, retainAll, toArray, toArray, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
equals, hashCode, parallelStream, removeIf, spliterator, stream, toArray
-
-
-
-
Method Detail
-
iterator
public Iterator<V> iterator()
Returns actually an instance ofListMap.ValuesIterator.- Specified by:
iteratorin interfaceCollection<V>- Specified by:
iteratorin interfaceIterable<V>- Specified by:
iteratorin classAbstractCollection<V>
-
size
public int size()
Returns actually the size of the enclosingListMapdelegating toListMap.size().- Specified by:
sizein interfaceCollection<V>- Specified by:
sizein classAbstractCollection<V>
-
contains
public boolean contains(Object obj)
Returns actually whetherobjis a value of the enclosingListMapdelegating toListMap.containsValue(Object).- Specified by:
containsin interfaceCollection<V>- Overrides:
containsin classAbstractCollection<V>
-
remove
public boolean remove(Object obj)
Interpretesobjas value of the enclosingListMapand removes the first according key-value pair if present. Returns whether the according key-value pair was present when invoking this method invoking usingListMap.removeIdx(int).- Specified by:
removein interfaceCollection<V>- Overrides:
removein classAbstractCollection<V>
-
clear
public void clear()
Clears actually the enclosingListMapdelegating toListMap.clear().- Specified by:
clearin interfaceCollection<V>- Overrides:
clearin classAbstractCollection<V>
-
-