T
- type of the counter for the group@InterfaceAudience.Public @InterfaceStability.Evolving public interface CounterGroupBase<T extends Counter> extends Writable, Iterable<T>
Modifier and Type | Method and Description |
---|---|
T |
addCounter(String name,
String displayName,
long value)
Add a counter to this group
|
void |
addCounter(T counter)
Add a counter to this group.
|
T |
findCounter(String counterName)
Find a counter in the group.
|
T |
findCounter(String counterName,
boolean create)
Find a counter in the group
|
T |
findCounter(String counterName,
String displayName)
Find a counter in the group.
|
String |
getDisplayName()
Get the display name of the group.
|
String |
getName()
Get the internal name of the group
|
void |
incrAllCounters(CounterGroupBase<T> rightGroup)
Increment all counters by a group of counters
|
void |
setDisplayName(String displayName)
Set the display name of the group
|
int |
size() |
readFields, write
String getName()
String getDisplayName()
void setDisplayName(String displayName)
displayName
- of the groupvoid addCounter(T counter)
counter
- to addT addCounter(String name, String displayName, long value)
name
- of the counterdisplayName
- of the countervalue
- of the counterT findCounter(String counterName, String displayName)
counterName
- the name of the counterdisplayName
- the display name of the counterT findCounter(String counterName, boolean create)
counterName
- the name of the countercreate
- create the counter if not found if trueT findCounter(String counterName)
counterName
- the name of the counterint size()
void incrAllCounters(CounterGroupBase<T> rightGroup)
rightGroup
- the group to be added to this groupCopyright © 2019 Apache Software Foundation. All rights reserved.