public class SummingHashMap<T1> extends HashMap<T1,Double>
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
SummingHashMap() |
Modifier and Type | Method and Description |
---|---|
void |
addMap(Map<T1,Double> map) |
void |
addValue(T1 key,
Double value) |
void |
addValue(T1 key,
Integer value) |
void |
divideBy(double denominator) |
SummingHashMap<T1> |
getCopy() |
T1 |
getMaximum() |
Double |
getSum() |
void |
incrementValue(T1 key)
Increments the count for @code key by 1.
|
void |
normalize() |
Double |
put(T1 key,
Double value) |
clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
equals, hashCode, toString
public void incrementValue(T1 key)
key
- The key for which the count will be incremented by one.public void divideBy(double denominator)
public Double getSum()
public void normalize()
public T1 getMaximum()
public SummingHashMap<T1> getCopy()
Copyright © 2018. All rights reserved.