IPBS_Station/SDK/include/CCJSONObject.h
2024-08-13 17:07:34 +08:00

26 lines
469 B
C++

#ifndef THREADPOOLDEMO_CCJSONOBJECT_H
#define THREADPOOLDEMO_CCJSONOBJECT_H
#include "nlohmann/json.hpp"
using JSON = nlohmann::json;
namespace CCJSON
{
JSON Parse(const char* str);
}
class CCJSONObject: public JSON
{
public:
CCJSONObject() = default;
CCJSONObject(JSON && j);
void Put(const char* key,nlohmann::json value);
JSON Get(const char* key);
std::string To_String();
private:
JSON j;
};
#endif //THREADPOOLDEMO_CCJSONOBJECT_H