public interface Counter extends Metric
Gauge Gauge to track a value that goes up and down.| Modifier and Type | Interface and Description |
|---|---|
static class |
Counter.Builder
Builder for
Counters. |
| Modifier and Type | Method and Description |
|---|---|
static Counter.Builder |
builder(String name)
Create new builder for
Counter. |
double |
count() |
default void |
increment()
Increment the counter by one.
|
void |
increment(double amount)
Increment the counter by
amount. |
static Counter.Builder builder(String name)
Counter.name - The name of the metric.Counter.default void increment()
void increment(double amount)
amount.amount - Amount to add to the counter.double count()
Copyright © 2018 WSO2. All rights reserved.