Package io.opencensus.implcore.metrics
Class MetricRegistryImpl
- java.lang.Object
-
- io.opencensus.metrics.MetricRegistry
-
- io.opencensus.implcore.metrics.MetricRegistryImpl
-
public final class MetricRegistryImpl extends MetricRegistry
Implementation ofMetricRegistry.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classMetricRegistryImpl.MetricProducerForRegistryprivate static classMetricRegistryImpl.RegisteredMeters
-
Field Summary
Fields Modifier and Type Field Description private Clockclockprivate MetricProducermetricProducerprivate MetricRegistryImpl.RegisteredMetersregisteredMeters
-
Constructor Summary
Constructors Constructor Description MetricRegistryImpl(Clock clock)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DerivedDoubleCumulativeaddDerivedDoubleCumulative(java.lang.String name, MetricOptions options)Builds a new derived double cumulative to be added to the registry.DerivedDoubleGaugeaddDerivedDoubleGauge(java.lang.String name, MetricOptions options)Builds a new derived double gauge to be added to the registry.DerivedLongCumulativeaddDerivedLongCumulative(java.lang.String name, MetricOptions options)Builds a new derived long cumulative to be added to the registry.DerivedLongGaugeaddDerivedLongGauge(java.lang.String name, MetricOptions options)Builds a new derived long gauge to be added to the registry.DoubleCumulativeaddDoubleCumulative(java.lang.String name, MetricOptions options)Builds a new double cumulative to be added to the registry.DoubleGaugeaddDoubleGauge(java.lang.String name, MetricOptions options)Builds a new double gauge to be added to the registry.LongCumulativeaddLongCumulative(java.lang.String name, MetricOptions options)Builds a new long cumulative to be added to the registry.LongGaugeaddLongGauge(java.lang.String name, MetricOptions options)Builds a new long gauge to be added to the registry.(package private) MetricProducergetMetricProducer()-
Methods inherited from class io.opencensus.metrics.MetricRegistry
addDerivedDoubleGauge, addDerivedLongGauge, addDoubleGauge, addLongGauge
-
-
-
-
Field Detail
-
registeredMeters
private final MetricRegistryImpl.RegisteredMeters registeredMeters
-
metricProducer
private final MetricProducer metricProducer
-
clock
private final Clock clock
-
-
Constructor Detail
-
MetricRegistryImpl
MetricRegistryImpl(Clock clock)
-
-
Method Detail
-
addLongGauge
public LongGauge addLongGauge(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new long gauge to be added to the registry. This is a more convenient form when you want to manually increase and decrease values as per your service requirements.- Specified by:
addLongGaugein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
LongGauge.
-
addDoubleGauge
public DoubleGauge addDoubleGauge(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new double gauge to be added to the registry. This is a more convenient form when you want to manually increase and decrease values as per your service requirements.- Specified by:
addDoubleGaugein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
DoubleGauge.
-
addDerivedLongGauge
public DerivedLongGauge addDerivedLongGauge(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new derived long gauge to be added to the registry. This is a more convenient form when you want to define a gauge by executing aToLongFunctionon an object.- Specified by:
addDerivedLongGaugein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
DerivedLongGauge.
-
addDerivedDoubleGauge
public DerivedDoubleGauge addDerivedDoubleGauge(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new derived double gauge to be added to the registry. This is a more convenient form when you want to define a gauge by executing aToDoubleFunctionon an object.- Specified by:
addDerivedDoubleGaugein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
DerivedDoubleGauge.
-
addLongCumulative
public LongCumulative addLongCumulative(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new long cumulative to be added to the registry. This is a more convenient form when you want to manually increase values as per your service requirements.- Specified by:
addLongCumulativein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
LongCumulative.
-
addDoubleCumulative
public DoubleCumulative addDoubleCumulative(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new double cumulative to be added to the registry. This is a more convenient form when you want to manually increase values as per your service requirements.- Specified by:
addDoubleCumulativein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
DoubleCumulative.
-
addDerivedLongCumulative
public DerivedLongCumulative addDerivedLongCumulative(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new derived long cumulative to be added to the registry. This is a more convenient form when you want to define a cumulative by executing aToLongFunctionon an object.- Specified by:
addDerivedLongCumulativein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
DerivedLongCumulative.
-
addDerivedDoubleCumulative
public DerivedDoubleCumulative addDerivedDoubleCumulative(java.lang.String name, MetricOptions options)
Description copied from class:MetricRegistryBuilds a new derived double cumulative to be added to the registry. This is a more convenient form when you want to define a cumulative by executing aToDoubleFunctionon an object.- Specified by:
addDerivedDoubleCumulativein classMetricRegistry- Parameters:
name- the name of the metric.options- the options for the metric.- Returns:
- a
DerivedDoubleCumulative.
-
getMetricProducer
MetricProducer getMetricProducer()
-
-