T
- public class AtomicCounterMap<T> extends java.lang.Object implements CounterMap<T>, HasBeenInstrumented
Modifier and Type | Field and Description |
---|---|
private java.util.concurrent.ConcurrentMap<T,java.util.concurrent.atomic.AtomicInteger> |
counters |
Constructor and Description |
---|
AtomicCounterMap() |
Modifier and Type | Method and Description |
---|---|
java.util.Map<T,java.lang.Integer> |
getFinalStateAndCleanIt() |
int |
getSize() |
int |
getValue(T key) |
void |
incrementValue(T key) |
void |
incrementValue(T key,
int inc) |
public AtomicCounterMap()
public final void incrementValue(T key, int inc)
incrementValue
in interface CounterMap<T>
public final void incrementValue(T key)
incrementValue
in interface CounterMap<T>
public final int getValue(T key)
getValue
in interface CounterMap<T>
public java.util.Map<T,java.lang.Integer> getFinalStateAndCleanIt()
getFinalStateAndCleanIt
in interface CounterMap<T>
public int getSize()