Class ACountHashMap<T>

java.lang.Object
org.apache.sysds.runtime.compress.utils.ACountHashMap<T>
All Implemented Interfaces:
Cloneable
Direct Known Subclasses:
DblArrayCountHashMap, DoubleCountHashMap

public abstract class ACountHashMap<T> extends Object implements Cloneable
  • Constructor Details

    • ACountHashMap

      public ACountHashMap()
    • ACountHashMap

      public ACountHashMap(int arrSize)
  • Method Details

    • size

      public int size()
    • increment

      public final int increment(T key)
      Increment and return the id of the incremented index.
      Parameters:
      key - The key to increment
      Returns:
      The id of the incremented entry.
    • increment

      public final int increment(double key)
    • increment

      public int increment(T key, int count)
      Increment and return the id of the incremented index.
      Parameters:
      key - The key to increment
      count - The number of times to increment the value
      Returns:
      The Id of the incremented entry.
    • increment

      public final int increment(double key, int count)
    • get

      public int get(T key)
    • getId

      public int getId(T key)
    • getC

      public ACount<T> getC(T key)
    • getOrDefault

      public int getOrDefault(T key, int def)
    • extractValues

      public final ACount<T>[] extractValues()
    • getMostFrequent

      public T getMostFrequent()
    • sortBuckets

      public void sortBuckets()
    • reset

      public void reset(int size)
    • toString

      public String toString()
      Overrides:
      toString in class Object