summaryrefslogtreecommitdiff
path: root/include/mbgl/style/layers/circle_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 15:33:50 +0200
commitc43d01cba40b7f47bcc9712d1b99eddb4134c870 (patch)
tree416a81ea30e43a3980d2afdd3fb4b94e76dc874c /include/mbgl/style/layers/circle_layer.hpp
parent56808731b699d7750726cd88dd06516c63d7f2f0 (diff)
downloadqtlocation-mapboxgl-upstream/mikhail_introduce_layer_factory.tar.gz
Introduce the style::Layer factory classesupstream/mikhail_introduce_layer_factory
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/circle_layer.hpp')
-rw-r--r--include/mbgl/style/layers/circle_layer.hpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/mbgl/style/layers/circle_layer.hpp b/include/mbgl/style/layers/circle_layer.hpp
index e0a121e2dc..dd22275b85 100644
--- a/include/mbgl/style/layers/circle_layer.hpp
+++ b/include/mbgl/style/layers/circle_layer.hpp
@@ -104,5 +104,13 @@ protected:
Mutable<Layer::Impl> mutableBaseImpl() const final;
};
+class CircleLayerFactory : public LayerFactory {
+protected:
+ // LayerFactory overrides.
+ ~CircleLayerFactory() 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