Modifier and Type | Method and Description |
---|---|
Gauge.Builder<T> |
baseUnit(String unit) |
Gauge.Builder<T> |
description(String description) |
Gauge.Builder |
hierarchicalName(String hierarchicalName) |
Gauge |
register(MeterRegistry registry)
Add the gauge to a single registry, or return an existing gauge in that registry.
|
Gauge.Builder<T> |
tag(String key,
String value) |
Gauge.Builder<T> |
tags(Iterable<Tag> tags) |
Gauge.Builder<T> |
tags(String... tags) |
public Gauge.Builder<T> tags(String... tags)
tags
- Must be an even number of arguments representing key/value pairs of tags.public Gauge.Builder<T> tags(Iterable<Tag> tags)
tags
- Tags to add to the eventual meter.public Gauge.Builder<T> tag(String key, String value)
key
- The tag key.value
- The tag value.public Gauge.Builder<T> description(@Nullable String description)
description
- Description text of the eventual gauge.public Gauge.Builder<T> baseUnit(@Nullable String unit)
unit
- Base unit of the eventual gauge.public Gauge.Builder hierarchicalName(String hierarchicalName)
hierarchicalName
- the hierarchical representation of the meter namepublic Gauge register(MeterRegistry registry)
registry
- A registry to add the gauge to, if it doesn't already exist.Copyright 2010-2018 ForgeRock AS.