Class ListMap.Node<K,V>
java.lang.Object
com.github.andrewoma.dexx.collection.internal.base.AbstractTraversable<Pair<K,V>>
com.github.andrewoma.dexx.collection.internal.base.AbstractIterable<Pair<K,V>>
com.github.andrewoma.dexx.collection.internal.base.AbstractMap<K,V>
com.github.andrewoma.dexx.collection.internal.hashmap.ListMap<K,V>
com.github.andrewoma.dexx.collection.internal.hashmap.ListMap.Node<K,V>
- All Implemented Interfaces:
Iterable<Pair<K,
,V>> Map<K,
,V> Traversable<Pair<K,
,V>> Iterable<Pair<K,
V>>
-
Nested Class Summary
Nested classes/interfaces inherited from class com.github.andrewoma.dexx.collection.internal.hashmap.ListMap
ListMap.Node<K,
V> -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
containsKey
(K key) Returns true if this map contains the specified key.Returns the value associated with the key ornull
if the no value exists with the key specified.protected K
getKey()
protected V
getValue()
boolean
isEmpty()
Returns true if this collection is empty.Returns a map with the value specified associated to the key specified.Returns a map with the value associated with the key removed if it exists.int
size()
Returns the size of the collection.private int
tail()
Methods inherited from class com.github.andrewoma.dexx.collection.internal.hashmap.ListMap
createNode, empty, factory, forEach, iterator
Methods inherited from class com.github.andrewoma.dexx.collection.internal.base.AbstractMap
asMap, equals, hashCode, keys, values
Methods inherited from class com.github.andrewoma.dexx.collection.internal.base.AbstractTraversable
makeString, makeString, to, toArray, toArray, toIndexedList, toSet, toSortedSet, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface com.github.andrewoma.dexx.collection.Traversable
makeString, makeString, to, toArray, toArray, toIndexedList, toSet, toSortedSet
-
Field Details
-
key
-
value
-
-
Constructor Details
-
Node
-
-
Method Details
-
size
public int size()Description copied from interface:Traversable
Returns the size of the collection.Warning: infinite collections are possible, as are collections that require traversal to calculate the size.
-
size0
-
isEmpty
public boolean isEmpty()Description copied from interface:Traversable
Returns true if this collection is empty. -
get
Description copied from interface:Map
Returns the value associated with the key ornull
if the no value exists with the key specified. -
apply0
-
tail
-
put
Description copied from interface:Map
Returns a map with the value specified associated to the key specified.If value already exists for the key, it will be replaced.
-
remove
Description copied from interface:Map
Returns a map with the value associated with the key removed if it exists. -
getKey
-
getValue
-
containsKey
Description copied from interface:Map
Returns true if this map contains the specified key.- Specified by:
containsKey
in interfaceMap<K,
V> - Overrides:
containsKey
in classListMap<K,
V>
-