Package org.h2.value

Class CaseInsensitiveMap<V>

  • Type Parameters:
    V - the value type
    All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, java.util.Map<java.lang.String,​V>

    public class CaseInsensitiveMap<V>
    extends java.util.HashMap<java.lang.String,​V>
    A hash map with a case-insensitive string key.
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.util.AbstractMap

        java.util.AbstractMap.SimpleEntry<K extends java.lang.Object,​V extends java.lang.Object>, java.util.AbstractMap.SimpleImmutableEntry<K extends java.lang.Object,​V extends java.lang.Object>
      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private static long serialVersionUID  
    • Constructor Summary

      Constructors 
      Constructor Description
      CaseInsensitiveMap()
      Creates new instance of case-insensitive map.
      CaseInsensitiveMap​(int initialCapacity)
      Creates new instance of case-insensitive map with specified initial capacity.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean containsKey​(java.lang.Object key)  
      V get​(java.lang.Object key)  
      V put​(java.lang.String key, V value)  
      V putIfAbsent​(java.lang.String key, V value)  
      V remove​(java.lang.Object key)  
      • Methods inherited from class java.util.HashMap

        clear, clone, compute, computeIfAbsent, computeIfPresent, containsValue, entrySet, forEach, getOrDefault, isEmpty, keySet, merge, putAll, remove, replace, replace, replaceAll, size, values
      • Methods inherited from class java.util.AbstractMap

        equals, hashCode, toString
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        equals, hashCode
    • Constructor Detail

      • CaseInsensitiveMap

        public CaseInsensitiveMap()
        Creates new instance of case-insensitive map.
      • CaseInsensitiveMap

        public CaseInsensitiveMap​(int initialCapacity)
        Creates new instance of case-insensitive map with specified initial capacity.
        Parameters:
        initialCapacity - the initial capacity
    • Method Detail

      • get

        public V get​(java.lang.Object key)
        Specified by:
        get in interface java.util.Map<java.lang.String,​V>
        Overrides:
        get in class java.util.HashMap<java.lang.String,​V>
      • put

        public V put​(java.lang.String key,
                     V value)
        Specified by:
        put in interface java.util.Map<java.lang.String,​V>
        Overrides:
        put in class java.util.HashMap<java.lang.String,​V>
      • putIfAbsent

        public V putIfAbsent​(java.lang.String key,
                             V value)
        Specified by:
        putIfAbsent in interface java.util.Map<java.lang.String,​V>
        Overrides:
        putIfAbsent in class java.util.HashMap<java.lang.String,​V>
      • containsKey

        public boolean containsKey​(java.lang.Object key)
        Specified by:
        containsKey in interface java.util.Map<java.lang.String,​V>
        Overrides:
        containsKey in class java.util.HashMap<java.lang.String,​V>
      • remove

        public V remove​(java.lang.Object key)
        Specified by:
        remove in interface java.util.Map<java.lang.String,​V>
        Overrides:
        remove in class java.util.HashMap<java.lang.String,​V>