refactor headers involving variant attempting to move as much variant usage out of hpp files to speed up compiles

This commit is contained in:
Dane Springmeyer 2013-01-12 21:00:45 -08:00
parent 577c04e3f9
commit bbcd53c6f4
29 changed files with 62 additions and 30 deletions

View file

@ -21,6 +21,8 @@
*****************************************************************************/
#include <boost/python.hpp>
#include <mapnik/value.hpp>
#include <mapnik/attribute.hpp>
#include <mapnik/building_symbolizer.hpp>
using namespace mapnik;

View file

@ -22,6 +22,7 @@
// boost
#include <boost/python.hpp>
#include <boost/variant.hpp>
// mapnik
//symbolizer typdef here rather than mapnik/symbolizer.hpp

View file

@ -27,6 +27,7 @@
#include <mapnik/transform_processor.hpp>
#include <mapnik/noncopyable.hpp>
#include <mapnik/attribute.hpp>
#include <mapnik/symbolizer.hpp> // for transform_list_ptr
#include <mapnik/building_symbolizer.hpp>
#include <mapnik/line_symbolizer.hpp>
#include <mapnik/line_pattern_symbolizer.hpp>
@ -39,15 +40,17 @@
#include <mapnik/markers_symbolizer.hpp>
#include <mapnik/rule.hpp> // for rule::symbolizers
#include <mapnik/expression.hpp> // for expression_ptr, etc
#include <mapnik/expression_node_types.hpp>
#include <mapnik/expression_node.hpp>
#include <mapnik/parse_path.hpp> // for path_processor_type
#include <mapnik/path_expression.hpp> // for path_expression_ptr
#include <mapnik/text_placements/base.hpp> // for text_placements
#include <mapnik/transform_expression.hpp>
// boost
#include <boost/variant.hpp>
#include <boost/concept_check.hpp>
#include <boost/variant/static_visitor.hpp>
#include <boost/variant/apply_visitor.hpp>
// stl
#include <set>

View file

@ -29,6 +29,8 @@
#include <mapnik/expression_node.hpp>
// boost
#include <boost/variant/static_visitor.hpp>
#include <boost/variant/apply_visitor.hpp>
#include <boost/regex.hpp>
#if defined(BOOST_REGEX_HAS_ICU)
#include <boost/regex/icu.hpp>

View file

@ -33,7 +33,6 @@
#if defined(BOOST_REGEX_HAS_ICU)
#include <boost/regex/icu.hpp>
#endif
#include <boost/variant.hpp>
#include <boost/function.hpp>
namespace mapnik

View file

@ -28,7 +28,9 @@
//#include <mapnik/attribute.hpp>
// boost
#include <boost/variant.hpp>
#include <boost/variant/variant_fwd.hpp>
namespace boost { template <typename T> class recursive_wrapper; }
namespace mapnik
{

View file

@ -26,7 +26,9 @@
// mapnik
#include <mapnik/config.hpp>
#include <mapnik/value.hpp>
// boost
#include <boost/variant/apply_visitor.hpp>
#include <boost/tuple/tuple.hpp>
#include <boost/iterator/iterator_traits.hpp>
#include <boost/iterator/iterator_facade.hpp>

View file

@ -46,6 +46,8 @@
#include <mapnik/proj_transform.hpp>
// boost
#include <boost/variant/apply_visitor.hpp>
#include <boost/variant/static_visitor.hpp>
#include <boost/foreach.hpp>
#include <boost/concept_check.hpp>

View file

@ -26,9 +26,12 @@
//mapnik
#include <mapnik/image_filter_types.hpp>
// boost
#include <boost/variant/static_visitor.hpp>
#include <boost/gil/gil_all.hpp>
#include <boost/concept_check.hpp>
// agg
#include "agg_basics.h"
#include "agg_rendering_buffer.h"

View file

@ -24,7 +24,7 @@
#define MAPNIK_IMAGE_FILTER_TYPES_HPP
// boost
#include <boost/variant.hpp>
#include <boost/variant/variant_fwd.hpp>
#include <boost/config/warning_disable.hpp>
// stl

View file

@ -29,11 +29,8 @@
#include <mapnik/feature.hpp>
// spirit::qi
#include <boost/config/warning_disable.hpp>
#include <boost/spirit/include/qi.hpp>
#include <boost/spirit/include/phoenix.hpp>
#include <boost/variant/apply_visitor.hpp>
#include <boost/variant/variant.hpp>
namespace mapnik { namespace json {

View file

@ -31,12 +31,11 @@
#include <mapnik/value.hpp>
// spirit::qi
#include <boost/config/warning_disable.hpp>
#include <boost/cstdint.hpp>
#include <boost/variant/static_visitor.hpp>
#include <boost/variant/apply_visitor.hpp>
#include <boost/spirit/include/qi.hpp>
#include <boost/spirit/include/phoenix.hpp>
#include <boost/variant/apply_visitor.hpp>
#include <boost/variant/variant.hpp>
#include <boost/variant/variant_fwd.hpp>
namespace mapnik { namespace json {

View file

@ -24,15 +24,12 @@
#define MAPNIK_GEOMETRY_GRAMMAR_HPP
// mapnik
#include <mapnik/geometry.hpp>
#include <mapnik/feature.hpp>
#include <mapnik/geometry.hpp> // for geometry_type
#include <mapnik/vertex.hpp> // for CommandType
// spirit::qi
#include <boost/config/warning_disable.hpp>
#include <boost/spirit/include/qi.hpp>
#include <boost/spirit/include/phoenix.hpp>
#include <boost/variant/apply_visitor.hpp>
#include <boost/variant/variant.hpp>
namespace mapnik { namespace json {

View file

@ -51,6 +51,7 @@
// boost
#include <boost/optional.hpp>
#include <boost/variant/apply_visitor.hpp>
namespace mapnik {

View file

@ -28,7 +28,7 @@
#include <mapnik/value_types.hpp>
// boost
#include <boost/variant/variant.hpp>
#include <boost/variant/variant_fwd.hpp>
#include <boost/optional.hpp>
// stl

View file

@ -25,14 +25,14 @@
// mapnik
#include <mapnik/config.hpp>
#include <mapnik/transform_expression.hpp>
#include <mapnik/symbolizer.hpp> // for transform_list_ptr
namespace mapnik {
template <typename Iterator> struct transform_expression_grammar;
typedef transform_expression_grammar<std::string::const_iterator>
transform_expression_grammar__string;
transform_expression_grammar_string;
MAPNIK_DECL transform_list_ptr parse_transform(std::string const& str);
@ -41,7 +41,7 @@ MAPNIK_DECL transform_list_ptr parse_transform(std::string const& str,
MAPNIK_DECL bool parse_transform(transform_list& list,
std::string const& str,
transform_expression_grammar__string const& g);
transform_expression_grammar_string const& g);
} // namespace mapnik

View file

@ -24,7 +24,7 @@
#define MAPNIK_PATH_EXPRESSION_HPP
// boost
#include <boost/variant.hpp>
#include <boost/variant/variant_fwd.hpp>
#include <boost/shared_ptr.hpp>
// stl

View file

@ -41,7 +41,7 @@
#include <mapnik/config.hpp> // MAPNIK_DECL
// boost
#include <boost/variant.hpp>
#include <boost/variant/variant_fwd.hpp>
// stl
#include <string>

View file

@ -38,6 +38,7 @@
#include <mapnik/pixel_position.hpp>
// boost
#include <boost/variant/static_visitor.hpp>
#include <boost/scoped_ptr.hpp>
#include <boost/shared_ptr.hpp>

View file

@ -27,18 +27,23 @@
#include <mapnik/config.hpp>
#include <mapnik/path_expression.hpp>
#include <mapnik/image_compositing.hpp>
#include <mapnik/transform_expression.hpp>
#include <mapnik/simplify.hpp>
// boost
#include <boost/array.hpp>
#include <boost/optional.hpp>
namespace agg { struct trans_affine; }
namespace mapnik
{
// fwd declares
// TODO - move these transform declares to own header
namespace detail { struct transform_node; }
typedef std::vector<detail::transform_node> transform_list;
typedef boost::shared_ptr<transform_list> transform_list_ptr;
typedef transform_list_ptr transform_type;
class Map;
class feature_impl;

View file

@ -29,7 +29,7 @@
// boost
#include <boost/optional.hpp>
#include <boost/shared_ptr.hpp>
#include <boost/variant.hpp>
#include <boost/variant/variant.hpp>
// fusion
#include <boost/fusion/include/at.hpp>

View file

@ -28,19 +28,22 @@
#ifdef MAPNIK_LOG
#include <mapnik/debug.hpp>
#endif
#include <mapnik/feature.hpp>
#include <mapnik/value.hpp>
#include <mapnik/transform_expression.hpp>
#include <mapnik/expression_evaluator.hpp>
// boost
#include <boost/foreach.hpp>
#include <boost/variant/static_visitor.hpp>
#include <boost/variant/apply_visitor.hpp>
// agg
#include <agg_trans_affine.h>
namespace mapnik {
class feature_impl;
template <typename Container> struct expression_attributes;
template <typename T>

View file

@ -30,7 +30,10 @@
#include <mapnik/util/conversions.hpp>
// boost
#include <boost/variant.hpp>
#include <boost/variant/recursive_wrapper.hpp>
#include <boost/variant/static_visitor.hpp>
#include <boost/variant/apply_visitor.hpp>
#include <boost/variant/variant.hpp>
#include <boost/scoped_array.hpp>
#include <boost/concept_check.hpp>

View file

@ -22,6 +22,8 @@
// mapnik
#include <mapnik/building_symbolizer.hpp>
#include <mapnik/value.hpp>
#include <mapnik/attribute.hpp>
namespace mapnik
{

View file

@ -22,6 +22,8 @@
// mapnik
#include <mapnik/markers_symbolizer.hpp>
#include <mapnik/value.hpp>
#include <mapnik/attribute.hpp>
// boost
#include <boost/make_shared.hpp>

View file

@ -39,7 +39,7 @@ transform_list_ptr parse_transform(std::string const& str, std::string const& en
transform_list_ptr tl = boost::make_shared<transform_list>();
transcoder tc(encoding);
expression_grammar<std::string::const_iterator> ge(tc);
transform_expression_grammar__string gte(ge);
transform_expression_grammar_string gte(ge);
if (!parse_transform(*tl, str, gte))
{
@ -50,7 +50,7 @@ transform_list_ptr parse_transform(std::string const& str, std::string const& en
bool parse_transform(transform_list& transform,
std::string const& str,
transform_expression_grammar__string const& g)
transform_expression_grammar_string const& g)
{
std::string::const_iterator itr = str.begin();
std::string::const_iterator end = str.end();

View file

@ -22,6 +22,8 @@
// mapnik
#include <mapnik/point_symbolizer.hpp>
#include <mapnik/value.hpp>
#include <mapnik/attribute.hpp>
#include <mapnik/enumeration.hpp>
namespace mapnik

View file

@ -22,6 +22,7 @@
// mapnik
#include <mapnik/rule.hpp>
#include <mapnik/expression_node.hpp>
#include <mapnik/debug.hpp>
#include <mapnik/raster_colorizer.hpp>
#include <mapnik/expression_string.hpp>

View file

@ -1,9 +1,12 @@
#include <boost/version.hpp>
#include <boost/detail/lightweight_test.hpp>
#include <iostream>
#include <mapnik/value_types.hpp>
#include <mapnik/params.hpp>
#include <mapnik/boolean.hpp>
#include <boost/variant.hpp>
int main( int, char*[] )
{