ClassFlowPostProcessing.h 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. #ifndef __FLOWPOSTPROCESSING__
  2. #define __FLOWPOSTPROCESSING__
  3. #include "ClassFlow.h"
  4. #include "ClassFlowMakeImage.h"
  5. #include "ClassFlowCNNGeneral.h"
  6. #include "ClassFlowDefineTypes.h"
  7. #include <string>
  8. class ClassFlowPostProcessing :
  9. public ClassFlow
  10. {
  11. protected:
  12. std::vector<NumberPost*> NUMBERS;
  13. bool UpdatePreValueINI;
  14. int PreValueAgeStartup;
  15. bool ErrorMessage;
  16. bool IgnoreLeadingNaN; // SPECIAL CASE for User Gustl ???
  17. ClassFlowCNNGeneral* flowAnalog;
  18. ClassFlowCNNGeneral* flowDigit;
  19. string FilePreValue;
  20. ClassFlowMakeImage *flowMakeImage;
  21. bool LoadPreValue(void);
  22. string ShiftDecimal(string in, int _decShift);
  23. string ErsetzteN(string, double _prevalue);
  24. float checkDigitConsistency(double input, int _decilamshift, bool _isanalog, double _preValue);
  25. void InitNUMBERS();
  26. void handleDecimalSeparator(string _decsep, string _value);
  27. void handleMaxRateValue(string _decsep, string _value);
  28. void handleDecimalExtendedResolution(string _decsep, string _value);
  29. void handleMaxRateType(string _decsep, string _value);
  30. void handleAnalogDigitalTransitionStart(string _decsep, string _value);
  31. std::string GetStringReadouts(general);
  32. void WriteDataLog(int _index);
  33. public:
  34. bool PreValueUse;
  35. ClassFlowPostProcessing(std::vector<ClassFlow*>* lfc, ClassFlowCNNGeneral *_analog, ClassFlowCNNGeneral *_digit);
  36. virtual ~ClassFlowPostProcessing(){};
  37. bool ReadParameter(FILE* pfile, string& aktparamgraph);
  38. bool doFlow(string time);
  39. string getReadout(int _number);
  40. string getReadoutParam(bool _rawValue, bool _noerror, int _number = 0);
  41. string getReadoutError(int _number = 0);
  42. string getReadoutRate(int _number = 0);
  43. string getReadoutTimeStamp(int _number = 0);
  44. void SavePreValue();
  45. string getJsonFromNumber(int i, std::string _lineend);
  46. string GetPreValue(std::string _number = "");
  47. void SetPreValue(double zw, string _numbers, bool _extern = false);
  48. std::string GetJSON(std::string _lineend = "\n");
  49. std::string getNumbersName();
  50. void UpdateNachkommaDecimalShift();
  51. std::vector<NumberPost*>* GetNumbers(){return &NUMBERS;};
  52. string name(){return "ClassFlowPostProcessing";};
  53. };
  54. #endif