Refactor JSON (#1518)

* use correct log level

* corrected logging

* typo

* refactored JSON generagion: removed unused parameters, consolidated into singel function, added "pre"

* Wrapped 'rate' into double quotes, like all other JSON values

Co-authored-by: CaCO3 <caco@ruinelli.ch>
This commit is contained in:
CaCO3
2022-12-09 17:49:26 +01:00
committed by GitHub
parent 88bdcc9365
commit 2768667eb1
6 changed files with 41 additions and 50 deletions

View File

@@ -61,10 +61,11 @@ public:
string getReadoutRate(int _number = 0);
string getReadoutTimeStamp(int _number = 0);
void SavePreValue();
string getJsonFromNumber(int i, std::string _lineend);
string GetPreValue(std::string _number = "");
void SetPreValue(double zw, string _numbers, bool _extern = false);
std::string GetJSON(std::string _id = "", std::string _mac = "", std::string _lineend = "\n");
std::string GetJSON(std::string _lineend = "\n");
std::string getNumbersName();
void UpdateNachkommaDecimalShift();