#include <ddtMonitorSamplesDialog.hpp>
Auxiliar class that calculate teh average value from samples over time based on a time window. Based on a previous tool DDT Monitor.
◆ SamplesAccumulator()
SamplesAccumulator::SamplesAccumulator |
( |
| ) |
|
|
inline |
◆ ReadableByteSize()
std::pair< float, char const * > SamplesAccumulator::ReadableByteSize |
( |
std::optional< float > | num_bytes | ) |
|
|
inline |
Method that updates the average of the samples value
- Parameters
-
num_bytes | Number to be converted in bytes |
- Returns
- res Pair of value and size dimension
◆ Reset()
void SamplesAccumulator::Reset |
( |
| ) |
|
|
inline |
Method that clean private variables and start accumulating from the beginning
◆ UpdateSamples()
std::optional< float > SamplesAccumulator::UpdateSamples |
( |
unsigned int | counter, |
|
|
std::chrono::system_clock::time_point | ts ) |
|
inline |
Method that updates the average of the samples value
- Parameters
-
counter | Number of samples to analyse |
ts | Point in time of the last received sample |
- Returns
- res Value of the last average of samples
The documentation for this class was generated from the following file: