Class CaseInsensitiveMap<V>
- Type Parameters:
V
- the type of value stored
- All Implemented Interfaces:
Serializable
,Map<String,
V>
An mapped collection where the keys are always strings and access to values is case-insensitive. The case of keys in
the map is maintained, but on any access to a key (directly or indirectly), all key comparisons are
performed in a case-insensitive manner. The map implementation is intended to support a reasonably finite number
(dozens or hundreds, not thousands or millions of key/value pairs. Unlike HashMap, it is based on a sorted list of
entries rather than hash bucket. It is also geared towards a largely static map, one that is created and then used
without modification.
- See Also:
-
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
ConstructorsConstructorDescriptionCaseInsensitiveMap
(int size) CaseInsensitiveMap
(Map<String, ? extends V> map) -
Method Summary
Methods inherited from class java.util.AbstractMap
clone, containsValue, equals, hashCode, putAll, toString, values
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Constructor Details
-
CaseInsensitiveMap
public CaseInsensitiveMap() -
CaseInsensitiveMap
-
CaseInsensitiveMap
-
-
Method Details
-
clear
-
isEmpty
-
size
-
put
-
containsKey
- Specified by:
containsKey
in interfaceMap<String,
V> - Overrides:
containsKey
in classAbstractMap<String,
V>
-
get
-
remove
-
entrySet
-
keySet
-