摘要: C++开发 cgi, 经常需要输出xml格式的数据。借鉴个to_json.hpp的库, 实现了个to_xml库, 可以方便输出xml数据。使用范例:#include "to_xml.hpp"#include <stdio.h>struct A{ int a; struct B { int i; std::string name; std::vector<std::string> other; DEF_TO_XML_MEM3(B, i, name, other) }; std::vector<int> b; B c; std::string 阅读全文
posted @ 2011-09-20 23:43 napoleon_liu 阅读(1726) 评论(1) 推荐(1) 编辑
摘要: C++开发 cgi, 经常需要输出json格式的数据。有些数据有重复的元素,每次写这些东西既容易出错,又繁琐。 在查看msgpack这个序列化库代码的时候,受到启发,写了个to_json.hpp的库,可以方便输出json数据。使用范例:#include "to_json.hpp"#include <stdio.h>struct A{ int a; struct B { int i; std::string name; std::vector<std::string> other; DEF_TO_JSON_MEM3(i, name, other) }; 阅读全文
posted @ 2011-09-20 11:25 napoleon_liu 阅读(3318) 评论(2) 推荐(2) 编辑
摘要: PumpManual Pump User's Manual Updated Nov 1, 2010 by w...@google.com The Problem Our Solution Highlights Examples Constructs Grammar Code Real E... 阅读全文
posted @ 2011-09-20 10:36 napoleon_liu 阅读(369) 评论(0) 推荐(0) 编辑