T
- the type of items stored in the set@ThingworxExtensionApiClass(since={8,1,1}) public interface IMetricSet<T> extends IMetric
METRIC_TYPE, VALUE, VALUE_TYPE
Modifier and Type | Method and Description |
---|---|
void |
add(T item)
Adds an item to the set. |
void |
add(T item,
boolean persist)
Adds an item to the set with optional persistence. |
void |
remove(T item)
Removes an item from the set, if it exists. |
void |
remove(T item,
boolean persist)
Removes an item from the set with optional persistence, if it exists. |
java.util.Set<T> |
snapshot()
Returns a snapshot of this metric's set. |
@ThingworxExtensionApiMethod(since={8,1,1}) void add(T item)
item
- the item to add@ThingworxExtensionApiMethod(since={8,3}) void add(T item, boolean persist)
item
- the item to addpersist
- whether or not to persist the metric set data@ThingworxExtensionApiMethod(since={8,1,1}) void remove(T item)
item
- the item to remove@ThingworxExtensionApiMethod(since={8,3}) void remove(T item, boolean persist)
item
- the item to removepersist
- whether or not to persist the metric set data@ThingworxExtensionApiMethod(since={8,3}) java.util.Set<T> snapshot()