artdaq_utilities
1.08.06
|
Small structure used to hold a metric data point before sending to the metric plugins More...
#include <artdaq-utilities/Plugins/MetricData.hh>
Classes | |
union | MetricDataValue |
This union holds the values for all other metric types More... | |
Public Member Functions | |
MetricData (const MetricData &r)=default | |
Default copy constructor More... | |
MetricData (MetricData &&r) noexcept=default | |
Default move constructor More... | |
MetricData & | operator= (const MetricData &r)=default |
Default copy assignment operator More... | |
MetricData & | operator= (MetricData &&r) noexcept=default |
Default move assignment operator More... | |
MetricData (std::string const &name, std::string const &value, std::string const &unit, int level, MetricMode mode, std::string const &metricPrefix, bool useNameOverride) | |
Construct a MetricData point using a string value More... | |
MetricData (std::string const &name, int const &value, std::string const &unit, int level, MetricMode mode, std::string const &metricPrefix, bool useNameOverride) | |
Construct a MetricData point using a int value More... | |
MetricData (std::string const &name, double const &value, std::string const &unit, int level, MetricMode mode, std::string const &metricPrefix, bool useNameOverride) | |
Construct a MetricData point using a double value More... | |
MetricData (std::string const &name, float const &value, std::string const &unit, int level, MetricMode mode, std::string const &metricPrefix, bool useNameOverride) | |
Construct a MetricData point using a float value More... | |
MetricData (std::string const &name, uint64_t const &value, std::string const &unit, int level, MetricMode mode, std::string const &metricPrefix, bool useNameOverride) | |
Construct a MetricData point using a uint64_t value More... | |
MetricData () | |
Default constructor, constructs an MetricType::InvalidMetric More... | |
bool | Add (MetricData other) |
Add two MetricData instances together More... | |
void | AddPoint (int point) |
Add an integer point to this MetricData More... | |
void | AddPoint (double point) |
Add a double point to this MetricData More... | |
void | AddPoint (float point) |
Add a float point to this MetricData More... | |
void | AddPoint (uint64_t point) |
Add an uint64_t point to this MetricData More... | |
void | Reset () |
Reset this MetricData instance to the initial state More... | |
Public Attributes | |
std::string | Name |
Name of the metric More... | |
std::string | StringValue |
Value of the metric, if it is a MetricType::StringMetric More... | |
MetricDataValue | Value |
Accumulated value of this MetricData More... | |
MetricDataValue | Last |
Last value of this MetricData. | |
MetricDataValue | Min |
Minimum recorded value of this MetricData. | |
MetricDataValue | Max |
Maximum recorded vaule of this MetricData. | |
MetricType | Type {MetricType::InvalidMetric} |
Type of the metric More... | |
std::string | Unit |
Units of the metric More... | |
int | Level |
Reporting level of the metric More... | |
MetricMode | Mode |
Accumulation mode of the metric More... | |
std::string | MetricPrefix |
Name prefix for the metric More... | |
bool | UseNameOverride |
Whether to override the default naming convention for this metric More... | |
size_t | DataPointCount {0} |
Number of data points accumulated in this MetricData More... | |
Small structure used to hold a metric data point before sending to the metric plugins
Definition at line 63 of file MetricData.hh.
|
default |
Default copy constructor
r | MetricData to copy |
|
defaultnoexcept |
Default move constructor
r | MetricData to move |
|
inline |
Construct a MetricData point using a string value
name | Name of the metric |
value | Value of the metric |
unit | Units of the metric |
level | Reporting level of the metric |
mode | Accumulation mode of the metric |
metricPrefix | Name prefix for the metric |
useNameOverride | Whether to override the default name |
Definition at line 188 of file MetricData.hh.
|
inline |
Construct a MetricData point using a int value
name | Name of the metric |
value | Value of the metric |
unit | Units of the metric |
level | Reporting level of the metric |
mode | Accumulation mode of the metric |
metricPrefix | Name prefix for the metric |
useNameOverride | Whether to override the default name |
Definition at line 202 of file MetricData.hh.
|
inline |
Construct a MetricData point using a double value
name | Name of the metric |
value | Value of the metric |
unit | Units of the metric |
level | Reporting level of the metric |
mode | Accumulation mode of the metric |
metricPrefix | Name prefix for the metric |
useNameOverride | Whether to override the default name |
Definition at line 216 of file MetricData.hh.
|
inline |
Construct a MetricData point using a float value
name | Name of the metric |
value | Value of the metric |
unit | Units of the metric |
level | Reporting level of the metric |
mode | Accumulation mode of the metric |
metricPrefix | Name prefix for the metric |
useNameOverride | Whether to override the default name |
Definition at line 230 of file MetricData.hh.
|
inline |
Construct a MetricData point using a uint64_t value
name | Name of the metric |
value | Value of the metric |
unit | Units of the metric |
level | Reporting level of the metric |
mode | Accumulation mode of the metric |
metricPrefix | Name prefix for the metric |
useNameOverride | Whether to override the default name |
Definition at line 244 of file MetricData.hh.
|
inline |
Default constructor, constructs an MetricType::InvalidMetric
Definition at line 251 of file MetricData.hh.
|
inline |
Add two MetricData instances together
other | MetricData to add to this one |
Definition at line 259 of file MetricData.hh.
|
inline |
Add an integer point to this MetricData
point | Int value to add |
Definition at line 346 of file MetricData.hh.
|
inline |
Add a double point to this MetricData
point | Double value to add |
Definition at line 358 of file MetricData.hh.
|
inline |
Add a float point to this MetricData
point | Float value to add |
Definition at line 370 of file MetricData.hh.
|
inline |
Add an uint64_t point to this MetricData
point | uint64_t value to add |
Definition at line 382 of file MetricData.hh.
|
default |
|
defaultnoexcept |
|
inline |
Reset this MetricData instance to the initial state
Sets the value, last and count fields to 0, the min to the maximum for the datatype and the max to the minimum for the datatype
Definition at line 396 of file MetricData.hh.
size_t artdaq::MetricData::DataPointCount {0} |
Number of data points accumulated in this MetricData
Definition at line 176 of file MetricData.hh.
int artdaq::MetricData::Level |
Reporting level of the metric
Definition at line 160 of file MetricData.hh.
std::string artdaq::MetricData::MetricPrefix |
Name prefix for the metric
Definition at line 168 of file MetricData.hh.
MetricMode artdaq::MetricData::Mode |
Accumulation mode of the metric
Definition at line 164 of file MetricData.hh.
std::string artdaq::MetricData::Name |
Name of the metric
Definition at line 94 of file MetricData.hh.
std::string artdaq::MetricData::StringValue |
Value of the metric, if it is a MetricType::StringMetric
Definition at line 98 of file MetricData.hh.
MetricType artdaq::MetricData::Type {MetricType::InvalidMetric} |
Type of the metric
Definition at line 152 of file MetricData.hh.
std::string artdaq::MetricData::Unit |
Units of the metric
Definition at line 156 of file MetricData.hh.
bool artdaq::MetricData::UseNameOverride |
Whether to override the default naming convention for this metric
Definition at line 172 of file MetricData.hh.
MetricDataValue artdaq::MetricData::Value |
Accumulated value of this MetricData
Definition at line 144 of file MetricData.hh.