public static interface DoubleCounter.Builder extends Counter.Builder
DoubleCounter.| Modifier and Type | Method and Description |
|---|---|
DoubleCounter |
build()
Builds and returns a
Instrument with the desired options. |
DoubleCounter.Builder |
setConstantLabels(Map<String,String> constantLabels)
Sets the map of constant labels (they will be added to all the Bound Instruments) for the
Instrument.
|
DoubleCounter.Builder |
setDescription(String description)
Sets the description of the
Instrument. |
DoubleCounter.Builder |
setLabelKeys(List<String> labelKeys)
Sets the list of label keys for the Instrument.
|
DoubleCounter.Builder |
setMonotonic(boolean monotonic)
Sets the monotonicity property for this
Counter. |
DoubleCounter.Builder |
setUnit(String unit)
Sets the unit of the
Instrument. |
DoubleCounter.Builder setDescription(String description)
Instrument.BuilderInstrument.
Default value is "".
setDescription in interface Counter.BuildersetDescription in interface Instrument.Builderdescription - the description of the Instrument.DoubleCounter.Builder setUnit(String unit)
Instrument.BuilderInstrument.
Default value is "1".
setUnit in interface Counter.BuildersetUnit in interface Instrument.Builderunit - the unit of the Instrument.DoubleCounter.Builder setLabelKeys(List<String> labelKeys)
Instrument.BuilderDefault value is Collections.emptyList()
setLabelKeys in interface Counter.BuildersetLabelKeys in interface Instrument.BuilderlabelKeys - the list of label keys for the Instrument.DoubleCounter.Builder setConstantLabels(Map<String,String> constantLabels)
Instrument.BuilderDefault value is Collections.emptyMap().
setConstantLabels in interface Counter.BuildersetConstantLabels in interface Instrument.BuilderconstantLabels - the map of constant labels for the Instrument.DoubleCounter.Builder setMonotonic(boolean monotonic)
Counter.BuilderCounter. If true only non-negative
values are expected.
Default value is true
setMonotonic in interface Counter.Buildermonotonic - true only positive values are expected.DoubleCounter build()
Instrument.BuilderInstrument with the desired options.build in interface Counter.Builderbuild in interface Instrument.BuilderInstrument with the desired options.