ulib/examples/main.cpp

15 lines
300 B
C++
Raw Normal View History

2023-12-26 20:58:36 +08:00
#include <json/json.h>
#include <ulib/log/log.h>
int
main(int argc, char *argv[])
{
ULOG_INFO("main", "hello world");
Json::Value root;
root["hello"] = "world";
// to string
std::string str = root.toStyledString();
ULOG_INFO("main", "json: {}", str.c_str());
return 0;
}