T - public final class ItemCounter<T> extends Object
| Constructor and Description | 
|---|
| ItemCounter() | 
| Modifier and Type | Method and Description | 
|---|---|
| void | add(T item,
   long delta)Add delta to the item | 
| List<T> | descendingKeys()Returns a List of keys in descending value order. | 
| boolean | equals(Object o) | 
| long | get(T item)Get current counter for an item item | 
| long | getAndSet(T item,
         long value)Set counter for item and return previous value | 
| int | hashCode() | 
| Set<T> | keySet()Returns an iterator over all keys. | 
| void | remove(T item) | 
| void | reset()Reset state of the counter to 0. | 
| void | set(T item,
   long value)Set counter of item to value | 
| String | toString() | 
public List<T> descendingKeys()
public long get(T item)
item - public void set(T item, long value)
item - to set set the value forvalue - a new valuepublic void add(T item, long delta)
item - delta - public void reset()
public long getAndSet(T item, long value)
item - value - public void remove(T item)
Copyright © 2016 Hazelcast, Inc.. All Rights Reserved.