com.threerings.stats.data
Class SetStat<T>
java.lang.Object
com.threerings.stats.data.Stat
com.threerings.stats.data.SetStat<T>
- All Implemented Interfaces:
- Streamable, DSet.Entry, Cloneable
- Direct Known Subclasses:
- IntSetStat, StringSetStat
public abstract class SetStat<T>
- extends Stat
|
Method Summary |
abstract boolean |
add(T key)
Adds the specified object to this set. |
abstract boolean |
contains(T key)
Returns true if the specified object is contained in this set. |
abstract int |
size()
Returns the number of elements in this set. |
| Methods inherited from class com.threerings.stats.data.Stat |
clone, crc32, getCode, getKey, getModCount, getType, getType, initType, isModified, persistTo, setModCount, setModified, toString, unpersistFrom, valueToString |
SetStat
public SetStat()
size
public abstract int size()
- Returns the number of elements in this set.
add
public abstract boolean add(T key)
- Adds the specified object to this set.
- Returns:
- true if the object was newly added, false if it was already
contained in the set.
contains
public abstract boolean contains(T key)
- Returns true if the specified object is contained in this set.