ClassFlow.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. #pragma once
  2. #include <fstream>
  3. #include <string>
  4. #include <vector>
  5. #include "Helper.h"
  6. #include "CImageBasis.h"
  7. using namespace std;
  8. #define LOGFILE_TIME_FORMAT "%Y%m%d-%H%M%S"
  9. #define LOGFILE_TIME_FORMAT_DATE_EXTR substr(0, 8)
  10. #define LOGFILE_TIME_FORMAT_HOUR_EXTR substr(9, 2)
  11. struct HTMLInfo
  12. {
  13. float val;
  14. CImageBasis *image = NULL;
  15. CImageBasis *image_org = NULL;
  16. std::string filename;
  17. std::string filename_org;
  18. };
  19. class ClassFlow
  20. {
  21. protected:
  22. // std::vector<string> ZerlegeZeile(string input);
  23. std::vector<string> ZerlegeZeile(string input, string delimiter = " =, \t");
  24. bool isNewParagraph(string input);
  25. bool GetNextParagraph(FILE* pfile, string& aktparamgraph);
  26. bool getNextLine(FILE* pfile, string* rt);
  27. std::vector<ClassFlow*>* ListFlowControll;
  28. ClassFlow *previousElement;
  29. virtual void SetInitialParameter(void);
  30. bool disabled;
  31. public:
  32. ClassFlow(void);
  33. ClassFlow(std::vector<ClassFlow*> * lfc);
  34. ClassFlow(std::vector<ClassFlow*> * lfc, ClassFlow *_prev);
  35. virtual bool ReadParameter(FILE* pfile, string &aktparamgraph);
  36. virtual bool doFlow(string time);
  37. virtual string getHTMLSingleStep(string host);
  38. virtual string getReadout();
  39. virtual string name(){return "ClassFlow";};
  40. };