Service_NSSM/SDK/include/CCJSONObject.h
“leonzor” c16ad2537c d
2025-03-06 13:47:33 +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