libmoost
moost::xml Namespace Reference

Classes

class  simple_parser
struct  get_opt_detail
struct  get_opt_detail< bool >

Functions

template<typename T >
static void get_opt (T &value, const std::string &key, const std::map< std::string, std::string > &optMap, bool throwIfNotFound=true)

Function Documentation

template<typename T >
static void moost::xml::get_opt ( T &  value,
const std::string &  key,
const std::map< std::string, std::string > &  optMap,
bool  throwIfNotFound = true 
) [static]

Free function to get the value off a map (generated with leaves2map for instance).

Parameters:
valueThe returned value.
keyThe key of the map.
optMapThe map.
throwIfNotFoundif true it will throw a runtime error if the key was not found in the map.

Definition at line 353 of file simple_parser.hpp.