KISSCPP
a C++ library for rapid application development
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
boost_ptree.hpp
Go to the documentation of this file.
1 // File : boost_ptree.hpp
2 // Author: Dirk J. Botha <bothadj@gmail.com>
3 //
4 // This file is part of kisscpp library.
5 //
6 // The kisscpp library is free software: you can redistribute it and/or modify
7 // it under the terms of the GNU Lesser General Public License as published by
8 // the Free Software Foundation, either version 3 of the License, or
9 // (at your option) any later version.
10 //
11 // The kisscpp library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU Lesser General Public License for more details.
15 //
16 // You should have received a copy of the GNU Lesser General Public License
17 // along with the kisscpp library. If not, see <http://www.gnu.org/licenses/>.
18 
19 #ifndef _BOOST_PTREE_HPP_
20 #define _BOOST_PTREE_HPP_
21 
22 #define BOOST_SPIRIT_THREADSAFE
23 
24 #include <string>
25 #include <boost/shared_ptr.hpp>
26 #include <boost/scoped_ptr.hpp>
27 #include <boost/property_tree/ptree.hpp>
28 #include <boost/property_tree/json_parser.hpp>
29 #include <boost/foreach.hpp>
30 
31 typedef boost::property_tree::ptree BoostPtree;
32 typedef boost::shared_ptr<BoostPtree> SharedPtree;
33 typedef boost::scoped_ptr<BoostPtree> ScopedPtree;
34 
35 namespace bpt = boost::property_tree;
36 
37 namespace kisscpp
38 {
39  void ptreeMerge (BoostPtree &pt1, BoostPtree &pt2, std::string node = "");
40  void ptreeAddOrPut(BoostPtree &pt1, std::string name, std::string value);
41 }
42 
43 #endif
boost::scoped_ptr< BoostPtree > ScopedPtree
Definition: boost_ptree.hpp:33
boost::property_tree::ptree BoostPtree
Definition: boost_ptree.hpp:31
void ptreeMerge(BoostPtree &pt1, BoostPtree &pt2, std::string node)
Definition: boost_ptree.cpp:7
void ptreeAddOrPut(BoostPtree &pt1, std::string name, std::string value)
Definition: boost_ptree.cpp:40
boost::shared_ptr< BoostPtree > SharedPtree
Definition: boost_ptree.hpp:32