summaryrefslogtreecommitdiff
path: root/include/mbgl/style/layers/heatmap_layer.hpp
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-10-28 22:33:06 +0200
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-10-31 18:05:01 +0200
commitcfcb53128b41941a9cdacfec18d618b0866a96bc (patch)
tree27ee48ad45fca144d21f71673137c470bbb19459 /include/mbgl/style/layers/heatmap_layer.hpp
parent278aa3370374154ad6fac7790d2da1546e8493f3 (diff)
downloadqtlocation-mapboxgl-cfcb53128b41941a9cdacfec18d618b0866a96bc.tar.gz
Introduce the style::Layer factory classes
This patch introduces the initial implementation of - A `LayerFactory` abstract class that creates `style::Layer` instances of a certain layer type (line, hillshade, round, ..) - A singleton `LayerManager` class, which is responsible for initializing the `LayerFactory` instances and forwarding the `create()` calls to the corresponding factory.
Diffstat (limited to 'include/mbgl/style/layers/heatmap_layer.hpp')
-rw-r--r--include/mbgl/style/layers/heatmap_layer.hpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/mbgl/style/layers/heatmap_layer.hpp b/include/mbgl/style/layers/heatmap_layer.hpp
index 5069eef165..3f53877523 100644
--- a/include/mbgl/style/layers/heatmap_layer.hpp
+++ b/include/mbgl/style/layers/heatmap_layer.hpp
@@ -69,5 +69,13 @@ protected:
Mutable<Layer::Impl> mutableBaseImpl() const final;
};
+class HeatmapLayerFactory : public LayerFactory {
+protected:
+ // LayerFactory overrides.
+ ~HeatmapLayerFactory() override;
+ const char* type() const final;
+ std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) override;
+};
+
} // namespace style
} // namespace mbgl