Klasse Long2FloatLinkedOpenCustomHashMap

Alle implementierten Schnittstellen:
Map<Long,Float>, Long2FloatFunction, Long2FloatMap, Long2FloatOrderedMap, ITrimmable

public class Long2FloatLinkedOpenCustomHashMap extends Long2FloatOpenCustomHashMap implements Long2FloatOrderedMap
A Type Specific LinkedHashMap that allows for custom HashControl. That uses arrays to create links between nodes. For cases where Objects/primitive do not allow hashcoding this can be really useful and provide a lot of control. This implementation of SortedMap does not support SubMaps of any kind. It implements the interface due to sortability and first/last access
  • Konstruktordetails

    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(LongStrategy strategy)
      Default Constructor
      Parameter:
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(int minCapacity, LongStrategy strategy)
      Constructor that defines the minimum capacity
      Parameter:
      minCapacity - the minimum capacity the HashMap is allowed to be.
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the minimum capacity is negative
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(int minCapacity, float loadFactor, LongStrategy strategy)
      Constructor that defines the minimum capacity and load factor
      Parameter:
      minCapacity - the minimum capacity the HashMap is allowed to be.
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the minimum capacity is negative
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(Long[] keys, Float[] values, LongStrategy strategy)
      Helper constructor that allow to create a map from boxed values (it will unbox them)
      Parameter:
      keys - the keys that should be put into the map
      values - the values that should be put into the map.
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the keys and values do not match in lenght
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(Long[] keys, Float[] values, float loadFactor, LongStrategy strategy)
      Helper constructor that allow to create a map from boxed values (it will unbox them)
      Parameter:
      keys - the keys that should be put into the map
      values - the values that should be put into the map.
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the keys and values do not match in lenght
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(long[] keys, float[] values, LongStrategy strategy)
      Helper constructor that allow to create a map from unboxed values
      Parameter:
      keys - the keys that should be put into the map
      values - the values that should be put into the map.
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the keys and values do not match in lenght
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(long[] keys, float[] values, float loadFactor, LongStrategy strategy)
      Helper constructor that allow to create a map from unboxed values
      Parameter:
      keys - the keys that should be put into the map
      values - the values that should be put into the map.
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the keys and values do not match in lenght
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(Map<? extends Long,? extends Float> map, LongStrategy strategy)
      A Helper constructor that allows to create a Map with exactly the same values as the provided map.
      Parameter:
      map - the values that should be present in the map
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(Map<? extends Long,? extends Float> map, float loadFactor, LongStrategy strategy)
      A Helper constructor that allows to create a Map with exactly the same values as the provided map.
      Parameter:
      map - the values that should be present in the map
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(Long2FloatMap map, LongStrategy strategy)
      A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
      Parameter:
      map - the values that should be present in the map
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • Long2FloatLinkedOpenCustomHashMap

      public Long2FloatLinkedOpenCustomHashMap(Long2FloatMap map, float loadFactor, LongStrategy strategy)
      A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
      Parameter:
      map - the values that should be present in the map
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
  • Methodendetails