BoostUtils.h File Reference

This file contains several utility functions for dealing with Boost containers and algorithms. More...

#include "Config.h"
#include <map>
#include <string>
#include <vector>
#include <boost/property_tree/ptree_fwd.hpp>
#include <boost/unordered_map.hpp>

Go to the source code of this file.

Namespaces

 te
 URI C++ Library.
 
 te::common
 Namespace for the Common module of TerraLib.
 

Functions

TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::map< std::string, std::string > &dict)
 Converts a property tree node into a std::map<std::string, std::string>. More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< std::pair< std::string, std::string > > &vp)
 Converts a property tree node into a std::vector<std::pair<std::string, std::string> > More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< std::string > &vect)
 Converts a property tree node into a std::vector<std::string>. More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< unsigned char > &vectd)
 Converts a property tree node into a std::vector<unsigned char>. More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< double > &vectd)
 Converts a property tree node into a std::vector<double>. More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< size_t > &vectd)
 Converts a property tree node into a std::vector<size_t>. More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< std::vector< double > > &vect)
 Converts a property tree node into a std::vector<vector<std::string> >. More...
 
TECOMMONEXPORT void te::common::Convert (const boost::property_tree::ptree &p, std::vector< std::map< std::string, std::string > > &vectm)
 Converts a property tree node into a std::vector<std::map<std::string, std::string> >. More...
 
TECOMMONEXPORT std::string te::common::ConvertLatin1UTFString (const std::string &data, const bool &toUtf=true)
 Converts a string from latin1 to utf8 and vice-versa. More...
 
template<class K , class V >
void te::common::FreeContents (boost::unordered_map< K, V * > &m)
 This function can be applied to a map of pointers. It will delete each pointer in the map. More...
 

Detailed Description

This file contains several utility functions for dealing with Boost containers and algorithms.

Definition in file BoostUtils.h.