Class Exemplar
Object
Exemplar
Immutable representation of an Exemplar.
-
Nested Class Summary
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic Exemplar.Builder
builder()
long
Will return garbage ifhasTimestamp()
isfalse
.double
getValue()
boolean
-
Field Details
-
TRACE_ID
Label name for trace id.- See Also:
-
SPAN_ID
Label name for span id.- See Also:
-
-
Constructor Details
-
Exemplar
To create a newExemplar
, you can either call the constructor directly or use the Builder withbuilder()
.- Parameters:
value
- the observed value. This is required.labels
- in most cases the labels will contain theTRACE_ID
andSPAN_ID
. Must not benull
. UseLabels.EMPTY
if no labels are present.timestampMillis
- timestamp when the value was observed. Optional. Use 0L if not available.
-
-
Method Details
-
getValue
-
getLabels
In most cases labels will containTRACE_ID
andSPAN_ID
, but this is not required. May beLabels.EMPTY
, but may not benull
. -
hasTimestamp
-
getTimestampMillis
Will return garbage ifhasTimestamp()
isfalse
. -
builder
-