Class ACountHashMap<T>
java.lang.Object
org.apache.sysds.runtime.compress.utils.ACountHashMap<T>
- All Implemented Interfaces:
Cloneable
- Direct Known Subclasses:
DblArrayCountHashMap,DoubleCountHashMap
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintintintgetOrDefault(T key, int def) final intincrement(double key) final intincrement(double key, int count) final intIncrement and return the id of the incremented index.intIncrement and return the id of the incremented index.voidreset(int size) intsize()voidtoString()
-
Constructor Details
-
ACountHashMap
public ACountHashMap() -
ACountHashMap
public ACountHashMap(int arrSize)
-
-
Method Details
-
size
public int size() -
increment
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
Increment and return the id of the incremented index.- Parameters:
key- The key to incrementcount- 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
-
getId
-
getC
-
getOrDefault
-
extractValues
-
getMostFrequent
-
sortBuckets
public void sortBuckets() -
reset
public void reset(int size) -
toString
-