ClassFlowWebhook.h 831 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #ifdef ENABLE_WEBHOOK
  2. #pragma once
  3. #ifndef CLASSFWEBHOOK_H
  4. #define CLASSFWEBHOOK_H
  5. #include "ClassFlow.h"
  6. #include "ClassFlowPostProcessing.h"
  7. #include <string>
  8. class ClassFlowWebhook :
  9. public ClassFlow
  10. {
  11. protected:
  12. std::string uri, apikey;
  13. ClassFlowPostProcessing* flowpostprocessing;
  14. bool WebhookEnable;
  15. void SetInitialParameter(void);
  16. void handleFieldname(string _decsep, string _value);
  17. void handleMeasurement(string _decsep, string _value);
  18. public:
  19. ClassFlowWebhook();
  20. ClassFlowWebhook(std::vector<ClassFlow*>* lfc);
  21. ClassFlowWebhook(std::vector<ClassFlow*>* lfc, ClassFlow *_prev);
  22. bool ReadParameter(FILE* pfile, string& aktparamgraph);
  23. bool doFlow(string time);
  24. string name(){return "ClassFlowWebhook";};
  25. };
  26. #endif //CLASSFWEBHOOK_H
  27. #endif //ENABLE_WEBHOOK