Class UnknownSnapshot.UnknownDataPointSnapshot
java.lang.Object
io.prometheus.metrics.model.snapshots.DataPointSnapshot
io.prometheus.metrics.model.snapshots.UnknownSnapshot.UnknownDataPointSnapshot
- Enclosing class:
- UnknownSnapshot
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionUnknownDataPointSnapshot(double value, Labels labels, Exemplar exemplar) To create a newUnknownSnapshot.UnknownDataPointSnapshot, you can either call the constructor directly or use the Builder withbuilder().UnknownDataPointSnapshot(double value, Labels labels, Exemplar exemplar, long scrapeTimestampMillis) Constructor with an additional scrape timestamp.privateUnknownDataPointSnapshot(double value, Labels labels, Exemplar exemplar, long scrapeTimestampMillis, boolean internal) -
Method Summary
Modifier and TypeMethodDescriptionbuilder()(package private) DataPointSnapshotescape(EscapingScheme escapingScheme) doublegetValue()Methods inherited from class io.prometheus.metrics.model.snapshots.DataPointSnapshot
getCreatedTimestampMillis, getLabels, getScrapeTimestampMillis, hasCreatedTimestamp, hasScrapeTimestamp
-
Field Details
-
value
private final double value -
exemplar
-
-
Constructor Details
-
UnknownDataPointSnapshot
To create a newUnknownSnapshot.UnknownDataPointSnapshot, you can either call the constructor directly or use the Builder withbuilder().- Parameters:
value- the value.labels- must not be null. UseLabels.EMPTYif there are no labels.exemplar- may be null.
-
UnknownDataPointSnapshot
public UnknownDataPointSnapshot(double value, Labels labels, Exemplar exemplar, long scrapeTimestampMillis) Constructor with an additional scrape timestamp. This is only useful in rare cases as the scrape timestamp is usually set by the Prometheus server during scraping. Exceptions include mirroring metrics with given timestamps from other metric sources. -
UnknownDataPointSnapshot
-
-
Method Details
-
getValue
public double getValue() -
getExemplar
-
builder
-
escape
- Specified by:
escapein classDataPointSnapshot
-