1 Star 0 Fork 8

fnet / ajson

forked from 丁宁 / ajson 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
example1_helloworld.cpp 424 Bytes
一键复制 编辑 原始数据 按行查看 历史
#include <iostream>
#include <string>
#include "ajson.hpp"
using namespace std;
using namespace ajson;
struct demo
{
string hello;
string world;
};
AJSON(demo,v.hello,v.world);
int main(int argc, char * argv[])
{
char * buff = "{\"hello\" : \"Hello\", \"world\" : \"world.\"}";
demo the_demo;
load_from_buff(the_demo,buff);
cout << the_demo.hello << " " << the_demo.world << std::endl;
cin.get();
return 0;
}
1
https://gitee.com/fnet/ajson.git
git@gitee.com:fnet/ajson.git
fnet
ajson
ajson
master

搜索帮助