T - The type of the state object from which the gauge value is extracted.public static class CallbackGauge.Builder<T> extends Object implements Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>
CallbackGauges.| Modifier and Type | Method and Description |
|---|---|
CallbackGauge.Builder<T> |
description(String description)
Set the description of the metric.
|
CallbackGauge |
register()
Create and register the metric with the default registry.
|
CallbackGauge |
register(MetricRegistry registry)
Create and register the metric with the given registry.
|
CallbackGauge.Builder |
tag(String key,
String value)
Add tags to this metric.
|
CallbackGauge.Builder |
tags(Iterable<Tag> tags)
Add tags to this metric.
|
CallbackGauge.Builder |
tags(Map<String,String> tags)
Add tags to this metric.
|
CallbackGauge.Builder |
tags(String... keyValues)
Add tags to this metric.
|
public CallbackGauge.Builder<T> description(String description)
Metric.Builderdescription in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>description - The description of the metric.public CallbackGauge.Builder tags(String... keyValues)
Metric.Buildertags in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>keyValues - Must be an even number of arguments representing key/value pairs of tags.public CallbackGauge.Builder tags(Iterable<Tag> tags)
Metric.Buildertags in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>tags - Tags to add to the metricspublic CallbackGauge.Builder tag(String key, String value)
Metric.Buildertag in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>key - The tag key.value - The tag value.public CallbackGauge.Builder tags(Map<String,String> tags)
Metric.Buildertags in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>tags - A map of key value pairs to be used as tagspublic CallbackGauge register()
Metric.Builderregister in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>public CallbackGauge register(MetricRegistry registry)
Metric.Builderregister in interface Metric.Builder<CallbackGauge.Builder<T>,CallbackGauge>registry - MetricRegistry to be usedCopyright © 2018 WSO2. All rights reserved.