[C] DuplicateTracker
Helper class to track duplicate instance
Type Parameters
Type Parameter |
---|
K |
V |
Constructors
new DuplicateTracker()
Returns
DuplicateTracker
<K
, V
>
Methods
entries()
Return iterator of all the duplicate entries.
Returns
Iterable
<[K
, V
[]], any
, any
>
track()
Track usage of K.
Parameters
Parameter | Type | Description |
---|---|---|
k | K | key that is being checked for duplicate. |
v | V | value that map to the key |
Returns
void