summaryrefslogtreecommitdiff
path: root/platform/android/src/style/layers/layer_manager.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'platform/android/src/style/layers/layer_manager.hpp')
-rw-r--r--platform/android/src/style/layers/layer_manager.hpp18
1 files changed, 16 insertions, 2 deletions
diff --git a/platform/android/src/style/layers/layer_manager.hpp b/platform/android/src/style/layers/layer_manager.hpp
index ff7e48027e..fb87721dd2 100644
--- a/platform/android/src/style/layers/layer_manager.hpp
+++ b/platform/android/src/style/layers/layer_manager.hpp
@@ -29,13 +29,27 @@ public:
private:
LayerManagerAndroid();
- void addLayerType(std::unique_ptr<JavaLayerPeerFactory>);
+ /**
+ * @brief Enables a layer type for both JSON style an runtime API.
+ */
+ void addLayerType(std::unique_ptr<JavaLayerPeerFactory>);
+ /**
+ * @brief Enables a layer type for JSON style only.
+ *
+ * We might not want to expose runtime API for some layer types
+ * in order to save binary size - JNI glue code for these layer types
+ * won't be added to the binary.
+ */
+ void addLayerTypeCoreOnly(std::unique_ptr<mbgl::LayerFactory>);
+
+ void registerCoreFactory(mbgl::LayerFactory*);
JavaLayerPeerFactory* getPeerFactory(const mbgl::style::LayerTypeInfo*);
// mbgl::LayerManager overrides.
LayerFactory* getFactory(const std::string& type) noexcept final;
LayerFactory* getFactory(const mbgl::style::LayerTypeInfo* info) noexcept final;
- std::vector<std::unique_ptr<JavaLayerPeerFactory>> factories;
+ std::vector<std::unique_ptr<JavaLayerPeerFactory>> peerFactories;
+ std::vector<std::unique_ptr<mbgl::LayerFactory>> coreFactories;
std::map<std::string, mbgl::LayerFactory*> typeToFactory;
};