24 #include <boost/spirit/include/qi.hpp> 25 #include <boost/algorithm/string.hpp> 37 bool Conv(
const string& str,
bool* out,
bool tryToCache )
50 if(
Conv(str, &i) && i == 0)
62 bool Conv(
const string& str,
Color* out,
bool tryToCache )
68 bool result = qi::phrase_parse(begin, end, color_, chs::space, *out);
70 return begin == end && result;
75 bool Conv(
const string& str,
string* out,
bool tryToCache )
90 boost::algorithm::trim(*out);
100 bool result = Conv<string>(str, &extr);
119 return v ?
"true" :
"false";
A grammar to parse a mapcss color.
bool Conv(const string &str, bool *out, bool tryToCache)
Use some extra function for bool conversion.
Represents a string which could be cached into an internal cache.
This file is part of alaCarte.
std::string::const_iterator StringIterator
Iterator to iterate over a file.
string ToString(const bool &v)
Represents a string which is cached into an internal cache.