Class Metric.Builder<B extends Metric.Builder<B,M>,M extends Metric>

java.lang.Object
io.prometheus.metrics.core.metrics.Metric.Builder<B,M>
Direct Known Subclasses:
MetricWithFixedMetadata.Builder
Enclosing class:
Metric

protected abstract static class Metric.Builder<B extends Metric.Builder<B,M>,M extends Metric> extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected io.prometheus.metrics.model.snapshots.Labels
     
    protected final List<String>
     
    protected final io.prometheus.metrics.config.PrometheusProperties
     
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    Builder(List<String> illegalLabelNames, io.prometheus.metrics.config.PrometheusProperties properties)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    abstract M
     
    constLabels(io.prometheus.metrics.model.snapshots.Labels constLabels)
     
     
    register(io.prometheus.metrics.model.registry.PrometheusRegistry registry)
     
    protected abstract B
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • illegalLabelNames

      protected final List<String> illegalLabelNames
    • properties

      protected final io.prometheus.metrics.config.PrometheusProperties properties
    • constLabels

      protected io.prometheus.metrics.model.snapshots.Labels constLabels
  • Constructor Details

    • Builder

      protected Builder(List<String> illegalLabelNames, io.prometheus.metrics.config.PrometheusProperties properties)
  • Method Details

    • constLabels

      public B constLabels(io.prometheus.metrics.model.snapshots.Labels constLabels)
    • register

      public M register()
    • register

      public M register(io.prometheus.metrics.model.registry.PrometheusRegistry registry)
    • build

      public abstract M build()
    • self

      protected abstract B self()