T - data type reported by the underlying Gaugeorg.eclipse.microprofile.metrics.Gauge<T>, org.eclipse.microprofile.metrics.Metricpublic class DelegatingGauge<T> extends Object implements org.eclipse.microprofile.metrics.Gauge<T>
Gauge for cataloging in the metrics registry that
delegates its getValue() method invocations to a discovered bean
method annotated with @Gauge.| Modifier and Type | Method | Description |
|---|---|---|
T |
getValue() |
|
static <S> DelegatingGauge<S> |
newInstance(Method method,
Object obj,
Class<S> clazz) |
Creates a new
DelegatingGauge which will defer to the specified
method on the object to retrieve the gauge of interest of the indicated type. |
public static <S> DelegatingGauge<S> newInstance(Method method, Object obj, Class<S> clazz)
DelegatingGauge which will defer to the specified
method on the object to retrieve the gauge of interest of the indicated type.S - type of the underlying gaugemethod - value-reporting method to be invoked to retrieve the gauge valueobj - bean instance from which to retrieve the gauge valueclazz - type of the underlying gaugeDelegatingGaugeCopyright © 2018, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.