Class ChainHashMap<K,V>

java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<K,V>
com.luna.common.map.ChainHashMap<K,V>
All Implemented Interfaces:
Serializable, Cloneable, Map<K,V>

public class ChainHashMap<K,V> extends HashMap<K,V>
Author:
luna
See Also:
  • Constructor Details

    • ChainHashMap

      public ChainHashMap(int initialCapacity)
    • ChainHashMap

      public ChainHashMap()
    • ChainHashMap

      public ChainHashMap(Map<? extends K,? extends V> m)
    • ChainHashMap

      public ChainHashMap(int initialCapacity, float loadFactor)
  • Method Details

    • newChainMap

      public static <K extends Comparable, V> ChainHashMap<K,V> newChainMap()
    • putIfNull

      public ChainHashMap<K,V> putIfNull(K key, V value)
      对 HashMap 的 put() 的方法进行封转返回 ChainHashMap 来实现 链式添加
      Parameters:
      key - k
      value - v
      Returns: