1#pragma once
2
3#include <mapbox/geometry.hpp>
4#include <mapbox/variant.hpp>
5
6namespace mapbox {
7namespace geojson {
8
9using value = mapbox::geometry::value;
10using null_value_t = mapbox::geometry::null_value_t;
11using identifier = mapbox::geometry::identifier;
12using point = mapbox::geometry::point<double>;
13using multi_point = mapbox::geometry::multi_point<double>;
14using line_string = mapbox::geometry::line_string<double>;
15using linear_ring = mapbox::geometry::linear_ring<double>;
16using multi_line_string = mapbox::geometry::multi_line_string<double>;
17using polygon = mapbox::geometry::polygon<double>;
18using multi_polygon = mapbox::geometry::multi_polygon<double>;
19using geometry = mapbox::geometry::geometry<double>;
20using geometry_collection = mapbox::geometry::geometry_collection<double>;
21using feature = mapbox::geometry::feature<double>;
22using feature_collection = mapbox::geometry::feature_collection<double>;
23
24// Parse inputs of known types. Instantiations are provided for geometry, feature, and
25// feature_collection.
26template <class T>
27T parse(const std::string &);
28
29// Parse any GeoJSON type.
30using geojson = mapbox::util::variant<geometry, feature, feature_collection>;
31geojson parse(const std::string &);
32
33// Stringify inputs of known types. Instantiations are provided for geometry, feature, and
34// feature_collection.
35template <class T>
36std::string stringify(const T &);
37
38// Stringify any GeoJSON type.
39std::string stringify(const geojson &);
40
41} // namespace geojson
42} // namespace mapbox
43

source code of qtlocation/src/3rdparty/mapbox-gl-native/deps/geojson/0.4.2/include/mapbox/geojson.hpp