1 #ifndef CARMA_MONITOR_MONITORPOINTSPECIALIZATIONS_H
2 #define CARMA_MONITOR_MONITORPOINTSPECIALIZATIONS_H
36 class MonitorPointThreshold;
41 typedef MonitorPointAverageT< ::std::string > MonitorPointAverageString;
42 typedef MonitorPointAverageT< ::std::complex< float > >
43 MonitorPointAverageComplex;
52 typedef char AccumReportType;
74 void setValue(
const char c,
int sampleIndex = 0)
const;
81 char getValue(
int sampleIndex = 0)
const;
153 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
161 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
183 (
const MonitorPointThreshold& threshold,
char charVal)
const;
203 typedef unsigned char AccumReportType;
225 void setValue(
const unsigned char c,
int sampleIndex = 0)
const;
232 unsigned char getValue(
int sampleIndex = 0)
const;
237 unsigned char getAve()
const;
298 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
306 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
328 (
const MonitorPointThreshold& threshold,
unsigned char byteVal)
const;
341 typedef short AccumReportType;
363 void setValue(
const short i,
int sampleIndex = 0)
const;
370 short getValue(
int sampleIndex = 0)
const;
436 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
444 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
466 (
const MonitorPointThreshold& threshold,
short shortVal)
const;
480 typedef long AccumReportType;
502 void setValue(
long i,
int sampleIndex = 0)
const;
509 long getValue(
int sampleIndex = 0)
const;
576 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
584 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
606 (
const MonitorPointThreshold& threshold,
long longVal)
const;
618 class MonitorPointBool:
public MonitorPoint {
621 typedef MonitorPointAverageBool AccumType;
622 typedef bool AccumReportType;
643 void setValue(
const bool b,
int sampleIndex = 0)
const;
650 bool getValue(
int sampleIndex = 0)
const;
655 virtual bool getAve()
const;
719 bool getWarnLow (
const MonitorPointThreshold& threshold)
const;
735 bool getWarnHigh (
const MonitorPointThreshold& threshold)
const;
751 bool getErrorLow (
const MonitorPointThreshold& threshold)
const;
767 bool getErrorHigh (
const MonitorPointThreshold& threshold)
const;
787 (AccumType & accum,
int index)
const;
796 virtual void accumulate (AccumType & accum)
const;
833 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
841 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
863 (
const MonitorPointThreshold& threshold,
bool boolVal)
const;
902 typedef int AccumReportType;
910 const bool bitmask =
false,
1021 (AccumType & accum,
int index)
const;
1030 virtual void accumulate (AccumType & accum)
const;
1067 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
1075 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
1091 (
const MonitorPointThreshold& threshold,
int enumVal)
const;
1096 ::std::string getRawStringForEnumValue(
int enumValue )
const;
1098 void setValue(
const long i,
int sampleNo)
const;
1099 int getValue(
int sampleNo)
const;
1113 const bool bitmask_;
1146 typedef float AccumReportType;
1168 void setValue(
const float f,
int sampleIndex = 0)
const;
1175 float getValue(
int sampleIndex = 0)
const;
1250 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
1259 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
1275 (
const MonitorPointThreshold& threshold,
float floatVal)
const;
1289 typedef double AccumReportType;
1311 void setValue(
const double f,
int sampleIndex = 0)
const;
1318 double getValue(
int sampleIndex = 0)
const;
1391 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
1400 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
1416 (
const MonitorPointThreshold& threshold,
double doubleVal)
const;
1428 class MonitorPointComplex:
public MonitorPoint {
1431 typedef MonitorPointAverageComplex AccumType;
1432 typedef ::std::complex< float > AccumReportType;
1447 } stringValueReturnType;
1469 void setValue(
const std::complex<float>& f,
int sampleIndex = 0)
const;
1476 std::complex<float>
getValue(
int sampleIndex = 0)
const;
1481 std::complex<float>
getAve()
const;
1544 (AccumType & accum,
int index)
const;
1553 virtual void accumulate (AccumType & accum)
const;
1590 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
1598 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
1614 (
const MonitorPointThreshold& threshold,
1615 std::complex<float> complexVal)
const;
1650 stringValueReturnType getStringRepresentation(
void)
const;
1671 stringValueReturnType stringReturnType_;
1685 typedef double AccumReportType;
1694 enum ABSTIME_FORMAT {
1729 void setValue(
const double f,
int sampleIndex = 0)
const;
1736 double getValue(
int sampleIndex = 0)
const;
1811 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
1819 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
1832 (
const MonitorPointThreshold& threshold,
double abstimeVal)
const;
1838 ABSTIME_FORMAT format_;
1842 class MonitorPointRA:
public MonitorPointDouble {
1848 MonitorPointRA(
const std::string& name,
1849 MONITOR_POINT_TYPE monitorPointType = MONITOR);
1855 virtual ~MonitorPointRA() {};
1857 virtual std::string getAverageToString()
const;
1859 class MonitorPointDec:
public MonitorPointDouble {
1865 MonitorPointDec(
const std::string& name,
1866 MONITOR_POINT_TYPE monitorPointType = MONITOR);
1872 virtual ~MonitorPointDec() {};
1874 virtual std::string getAverageToString()
const;
1892 typedef ::std::string AccumReportType;
1916 void setValue(
const std::string& str)
const;
1927 std::string
getAve()
const;
1991 std::string
getWarnLow (
const MonitorPointThreshold& threshold)
const;
2007 std::string
getWarnHigh (
const MonitorPointThreshold& threshold)
const;
2023 std::string
getErrorLow (
const MonitorPointThreshold& threshold)
const;
2039 std::string
getErrorHigh (
const MonitorPointThreshold& threshold)
const;
2059 (AccumType & accum,
int index)
const;
2068 virtual void accumulate (AccumType & accum)
const;
2105 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
2113 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
2129 (
const MonitorPointThreshold& threshold,
2130 std::string stringVal)
const;
2153 typedef long AccumReportType;
2175 void setValue(
long i,
int sampleIndex = 0)
const;
2182 int getValue(
int sampleIndex = 0)
const;
2219 (AccumType & accum,
int index)
const;
2228 virtual void accumulate (AccumType & accum)
const;
2265 virtual AccumReportType
getMaxValue (
const AccumType & accum)
const;
2273 virtual AccumReportType
getMinValue (
const AccumType & accum)
const;
2289 (
const MonitorPointThreshold& threshold,
long serialNoVal)
const;
2305 return getAveChar();
2309 inline unsigned char
2312 return static_cast< unsigned char >( getAveChar() );
2319 return getAveShort();
2326 return getAveLong();
2331 carma::monitor::MonitorPointEnum::getAve( )
const
2333 return getAveLong();
2340 return getAveFloat();
2347 return getAveDouble();
2351 inline ::std::complex< float >
2354 return getAveComplex();
2361 return getAveDouble();
2365 inline ::std::string
2375 return getAveSerialNo();
void setValue(const std::string &str) const
Set the value.
void setWarnLowDefault(const double threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
virtual void accumulate(AccumType &accum) const
Accumulate values from current monitor point for computing averages.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
void setFormat(ABSTIME_FORMAT format)
Select output format type.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, long longVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
VALIDITY
Validity states of the data value.
virtual double getAveNumeric() const
Returns average sample value as a double.
void setWarnHighDefault(const float threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual ~MonitorPointAbstime()
Destructor.
short MonitorValueType
Enumeration of possible types for monitor point values.
double getValue(int sampleIndex=0) const
Get the value.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
void setErrorLowDefault(bool boolVal)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
void setWarnHighDefault(const char threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
virtual short getWidth() const
Get the string length to use when interpreting the value to a string.
virtual enum MonitorPoint::VALIDITY accumulateSample(AccumType &accum, int index) const
Accumulates data from one monitor point sample (sample index == index) belonging this monitor point...
void setErrorLowDefault(const std::string strValue)
Sets lower error threshold to be strValue.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
double getValue(int sampleIndex=0) const
Get the value.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
virtual void resetAccumulator(AccumType &accum) const
Reset accumulator values from for computing averages.
unsigned char getAve() const
Get the average value.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
void setValue(const double f, int sampleIndex=0) const
Set the value.
MonitorPointDouble(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
MonitorPointFloat(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
void setErrorHighDefault(const unsigned char threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, float floatVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
void removeEnumErrorLowDefault(const long enumValue)
Remove enum value from default error high threshold.
MonitorPointSerialNo(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
long getValue(int sampleIndex=0) const
Get the value.
void setErrorHighDefault(bool boolVal)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
std::complex< float > getMaxSampleValue() const
Gets the maximum sample value (measured as max norm).
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
getValueString() will return the real part
virtual void resetAccumulator(AccumType &accum) const
Reset accumulator values from for computing averages.
void setErrorLowDefault(const char threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
virtual enum MonitorPoint::VALIDITY accumulateSample(AccumType &accum, int index) const
Accumulates data from one monitor point sample (sample index == index) belonging this monitor point...
char getAve() const
Get the average value.
getValueString() will return the full complex value
void setErrorHighDefault(const std::string strValue)
Sets upper error threshold to be strValue.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
virtual double getAveNumeric() const
Returns average sample value as a double.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
getValueString() will return the amplitude
void setWarnLowDefault(bool boolVal)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
void setErrorHighDefault(const float threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
Long integer value monitor point (4 bytes).
getValueString() will return the imaginary part
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
Base class for all real value monitor points (float, double, etc).
virtual void accumulate(AccumType &accum) const
Accumulate values from current monitor point for computing averages.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual void resetAccumulator(AccumType &accum) const
Reset accumulator values from for computing averages.
void addEnumErrorLowDefault(const long enumValue)
Add default error low threshold.
getValueString() will return the phase
void setWarnHighDefault(bool boolVal)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
bool getErrorLow(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_LOW_ERROR_VALUE for this monitor point.
virtual ~MonitorPointByte()
Destructor.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
short getValue(int sampleIndex=0) const
Get the value.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, double doubleVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
ABSTIME_FORMAT getFormat() const
Get output format type.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
String value monitor point (up to 80 characters in length).
void setStringRepresentation(const stringValueReturnType &type)
Decide how to treat complex number returned as string.
unsigned char getValue(int sampleIndex=0) const
Get the value.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
long getAve() const
Get the average value.
std::string getWarnLow(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_LOW_WARN_VALUE for this monitor point.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
MonitorPointAbstime(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
virtual ~MonitorPointFloat()
Destructor.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
void setWarnHighDefault(const short threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, unsigned char byteVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
void setValue(const char c, int sampleIndex=0) const
Set the value.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, short shortVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
double getAve() const
Get the average value.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
void setValue(const unsigned char c, int sampleIndex=0) const
Set the value.
bool operator==(const MonitorComponent &component) const
Compares this monitor point for equality to the one passed.
virtual void accumulateAverage(AccumType &accum)
Accumulates pre-calculated average value from current monitor point for computing averages...
void removeEnumErrorHighDefault(const long enumValue)
Remove enum value from default error low threshold.
Abstract base class for any enumerated constants, like state machines.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
Serial number monitor point, stored as integer value(4 bytes).
void setErrorHighDefault(const double threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual double getAveNumeric() const
Returns average sample value as a double.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
void setErrorHighDefault(const char threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
MonitorPointComplex(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
void setValue(const float f, int sampleIndex=0) const
Set the value.
virtual double getAveNumeric() const
Returns average sample value as a double.
void setErrorHighDefault(const double threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual void accumulateAverage(AccumType &accum)
Accumulates pre-calculated average value from current monitor point for computing averages...
char getValue(int sampleIndex=0) const
Get the value.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
bool operator==(const MonitorComponent &component) const
Compares this monitor point for equality to the one passed.
std::string getErrorHigh(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual double getAveNumeric() const
Returns average sample value as a double.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
void setValue(const short i, int sampleIndex=0) const
Set the value.
std::string getWarnHigh(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_HIGH_WARN_VALUE for this monitor point.
Float value monitor point.
virtual void accumulateAverage(AccumType &accum)
Accumulates pre-calculated average value from current monitor point for computing averages...
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, char charVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
bool getErrorHigh(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
void setWarnLowDefault(const short threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
virtual ~MonitorPointComplex()
Destructor.
std::string getErrorLow(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_LOW_ERROR_VALUE for this monitor point.
std::string getValue() const
Get the value.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
void setErrorHighDefault(const short threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
void setWarnHighDefault(const unsigned char threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
int getNumEnumerations() const
Get the number of enumerations.
void setWarnLowDefault(const long threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
void setErrorHighDefault(const long threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
std::complex< float > getAve() const
Get the average value.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
void setWarnHighDefault(const long threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
MonitorPointChar(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
void setWarnLowDefault(const char threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
Character value monitor point.
MonitorPointBool(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
MonitorPointInt(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
int getValue(int sampleIndex=0) const
Get the value.
void setValue(const double f, int sampleIndex=0) const
Set the value.
void setErrorLowDefault(const double threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
void setWarnLowDefault(const float threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
virtual ~MonitorPointChar()
Destructor.
void setWarnLowDefault(const float threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
MonitorPointString(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
void setWarnHighDefault(const double threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
short getPrecision() const
Get the number of digits to the right of the decimal point for interpreting the value to a string...
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
void setWarnHighDefault(const float threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual void accumulate(AccumType &accum) const
Accumulate values from current monitor point for computing averages.
virtual void accumulate(AccumType &accum) const
Accumulate values from current monitor point for computing averages.
void setValue(const std::complex< float > &f, int sampleIndex=0) const
Set the value.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
void addEnumErrorHighDefault(const long enumValue)
Add default error high threshold.
void addEnumWarnLowDefault(const long enumValue)
Add default warning low threshold.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
virtual void accumulateAverage(AccumType &accum)
Accumulates pre-calculated average value from current monitor point for computing averages...
Abstract base class for a monitor point.
short getAve() const
Get the average value.
virtual std::string getAverageToString() const
Abstract method that returns the average value as a string.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
void setErrorLowDefault(const unsigned char threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, long serialNoVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
virtual enum MonitorPoint::VALIDITY accumulateSample(AccumType &accum, int index) const
Accumulates data from one monitor point sample (sample index == index) belonging this monitor point...
void setWarnLowDefault(const std::string strValue)
Sets lower warning threshold to be strValue.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
void removeEnumWarnHighDefault(const long enumValue)
Remove enum value from default warning high threshold.
std::string getFormattedAbstime(double mjd) const
Format an mjd according to the selected format.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
bool getWarnHigh(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
~MonitorPointString()
Destructor.
bool isBitmask() const
Is this monitor point enumeration a bitmask.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, std::complex< float > complexVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
void setErrorLowDefault(const short threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
~MonitorPointEnum()
Destructor.
float getValue(int sampleIndex=0) const
Get the value.
virtual enum MonitorPoint::VALIDITY accumulateSample(AccumType &accum, int index) const
Accumulates data from one monitor point sample (sample index == index) belonging this monitor point...
virtual bool getAve() const
Get the average value.
MonitorPointShort(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, int enumVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
MONITOR_POINT_TYPE
Monitor point type.
Byte value (unsigned char) monitor point.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, double abstimeVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
int getAve() const
Get the average value.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
virtual void resetAccumulator(AccumType &accum) const
Reset accumulator values from for computing averages.
Double value monitor point.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
float getAve() const
Get the average value.
virtual double getAveNumeric() const
Returns average sample value as a double.
A composite interface used to build the monitor system hierarchy.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
std::complex< float > getValue(int sampleIndex=0) const
Get the value.
void removeEnumWarnLowDefault(const long enumValue)
Remove enum value from default warning low threshold.
virtual void resetAccumulator(AccumType &accum) const
Reset accumulator values from for computing averages.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
~MonitorPointSerialNo()
Destructor.
void setNumEnumerations(int num)
Set the number of enumerations.
void setErrorLowDefault(const float threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
void setErrorLowDefault(const float threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
virtual AccumReportType getAccumulatedAverage(const AccumType &accum) const
Compute average from accumulated values in accumulator object.
void setErrorHighDefault(const float threshold)
Sets THRESHOLD_HIGH_ERROR_VALUE for this monitor point.
double getAve() const
Get the average value.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, std::string stringVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual double getAveNumeric() const
Returns average sample value as a double.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
virtual ~MonitorPointBool()
Destructor.
void setErrorLowDefault(const double threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
bool getWarnLow(const MonitorPointThreshold &threshold) const
Returns current THRESHOLD_LOW_WARN_VALUE for this monitor point.
virtual void evaluateTolerance(const MonitorPointThreshold &threshold)
Set the validity flags for the MonitorPoint using the threshold limits stored in the input MonitorPoi...
void setPrecision(short precision)
Set the number of digits to the right of the decimal point for interpreting the value to a string...
std::string getValueToString() const
Gets the full string stored for this mp.
virtual std::string convertToString(int enumValue) const =0
Convert an integer value, interpreted as an enum, into a string.
void setValue(const bool b, int sampleIndex=0) const
Set the value.
~MonitorPointShort()
Destructor.
Abstract base class for all monitor points that can be represented as a number.
void setWarnHighDefault(const std::string strValue)
Sets upper warning threshold to be strValue.
virtual enum MonitorPoint::VALIDITY evaluateSampleTolerance(const MonitorPointThreshold &threshold, bool boolVal) const
Method to return validity for a sample using the range parameters in the MonitorPointThreshold object...
std::complex< float > getMinSampleValue() const
Gets the minimum sample value (measured as min norm).
virtual void accumulateAverage(AccumType &accum)
Accumulates pre-calculated average value from current monitor point for computing averages...
virtual enum MonitorPoint::VALIDITY accumulateSample(AccumType &accum, int index) const
Accumulates data from one monitor point sample (sample index == index) belonging this monitor point...
bool getValue(int sampleIndex=0) const
Get the value.
Short integer value monitor point (2 bytes).
virtual ~MonitorPointReal()
Destructor.
void setWarnLowDefault(const double threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
void setValue(long i, int sampleIndex=0) const
Set the value.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
virtual ~MonitorPointDouble()
Destructor.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
Absolute time value monitor point.
MonitorPointEnum(const std::string &name, const bool bitmask=false, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
void setWarnLowDefault(const unsigned char threshold)
Sets THRESHOLD_LOW_WARN_VALUE for this monitor point.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
void setValue(long i, int sampleIndex=0) const
Set the value.
virtual AccumReportType getMinValue(const AccumType &accum) const
Returns minimum value from accumulated data in accumulator object.
MonitorPointReal(const std::string &name, MonitorValueType monitorValueType, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
void setWarnHighDefault(const double threshold)
Sets THRESHOLD_HIGH_WARN_VALUE for this monitor point.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
~MonitorPointInt()
Destructor.
virtual void updateFrameAverage(ScratchAverages &scratchAvgs)
Abstract method that updates the average value/validity for the frame.
void addEnumWarnHighDefault(const long enumValue)
Add default warning high threshold.
void setErrorLowDefault(const long threshold)
Sets THRESHOLD_LOW_ERROR_VALUE for this monitor point.
std::string getAve() const
Get the average value.
Abstract base class for a numeric monitor point.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
void setNumSamples(int nSamples) const
Set the number of samples to one...
MonitorPointByte(const std::string &name, MONITOR_POINT_TYPE monitorPointType=MONITOR)
Constructor.
virtual double getValueNumeric(int sampleIndex) const
Returns sample value as a double.
virtual std::string getValueToString(int sampleIndex=0) const
Abstract method that returns the data value as a string.
virtual void accumulate(AccumType &accum) const
Accumulate values from current monitor point for computing averages.
virtual AccumReportType getMaxValue(const AccumType &accum) const
Returns maximum value from accumulated data in accumulator object.
virtual std::string getAccumulatedAverageAsString(const AccumType &accum) const
Create and return string representation for average accumulated in accumulator object.