| Modifier and Type | Method and Description |
|---|---|
void |
increment()
Increment the counter by 1.
|
void |
increment(long amount)
Increment the counter by the provided amount.
|
java.lang.String |
toString() |
MetricsContext.Unit |
unit()
The unit of the counter.
|
long |
value()
Reports the current count.
|
public static final Counter NOOP
public void increment()
Counterpublic void increment(long amount)
CounterImplementations may skip the overflow check for better write throughput.
public long value()
Counterpublic java.lang.String toString()
toString in class java.lang.Objectpublic MetricsContext.Unit unit()
Counter