Package com.yahoo.statistics
Class Value.Parameters
java.lang.Object
com.yahoo.statistics.Value.Parameters
- Enclosing class:
- Value
Parameters for building Value instances. All settings are classes instead
of primitive types to allow tri-state logic (true, false, unset).
-
Constructor Summary
ConstructorDescriptionGet a fresh Parameters instance with all features turned/unset. -
Method Summary
Modifier and TypeMethodDescriptionsetAppendChar
(Character appendChar) Separator character to use between event name and type of nameExtension is set to true.setCallback
(Callback callback) Set a callback to be invoked each time this Value is written to the log.setHistogramId
(HistogramType histogramId) What kind of histogram to log.The limits to use if logging as a histogram.setLogHistogram
(Boolean logHistogram) (De-)Activate logging a data histogram.setLogInsertions
(Boolean logInsertions) (De-)Activate loging the number of observations for each interval.(De-)Activate logging the maximal value observed for each interval.setLogMean
(Boolean logMean) (De)-activate loging the mean value for each interval.(De-)Activate logging the minimal value observed for each interval.(De-)Activate logging of raw values.(De-)Activate logging the sum of all data points for each interval.setNameExtension
(Boolean nameExtension) Whether or not to add an identifying extension (like mean) to event names when logging derived values.
-
Constructor Details
-
Parameters
public Parameters()Get a fresh Parameters instance with all features turned/unset. Parameters instances may be recycled for construction multiple Value instances, but do note any Limits instance added must be frozen.
-
-
Method Details
-
setLogRaw
(De-)Activate logging of raw values. Raw values are basically the last value logged.- Returns:
- "this" for call chaining
-
setLogSum
(De-)Activate logging the sum of all data points for each interval.- Returns:
- "this" for call chaining
-
setLogMean
(De)-activate loging the mean value for each interval.- Returns:
- "this" for call chaining
-
setLogMax
(De-)Activate logging the maximal value observed for each interval.- Returns:
- "this" for call chaining
-
setLogMin
(De-)Activate logging the minimal value observed for each interval.- Returns:
- "this" for call chaining
-
setLogInsertions
(De-)Activate loging the number of observations for each interval.- Returns:
- "this" for call chaining
-
setNameExtension
Whether or not to add an identifying extension (like mean) to event names when logging derived values. It is useful to disable extensions if a only a single dervied value, e.g. the mean, is the only thing to be logged. The default is to use extensions. If extensions are disabled, the ability to log more than one of raw value, min, max, mean (i.e. the raw value and derived values of the same type) is disabled to avoid confusion. Since histograms are not Value events, these never have a name extension and are always available.- Returns:
- "this" for call chaining
-
setLogHistogram
(De-)Activate logging a data histogram.- Returns:
- "this" for call chaining
-
setHistogramId
What kind of histogram to log.- Returns:
- "this" for call chaining
- See Also:
-
setLimits
The limits to use if logging as a histogram. The Limits instance must be frozen before using the Parameters instance in a Value constructor call.- Returns:
- "this" for call chaining*
- See Also:
-
setAppendChar
Separator character to use between event name and type of nameExtension is set to true. The default is '.'.- Returns:
- "this" for call chaining
-
setCallback
Set a callback to be invoked each time this Value is written to the log.- Parameters:
callback
- to be invoked each time the Value is written to the log- Returns:
- "this" for call chaining
-