summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBruno de Oliveira Abinader <bruno@mapbox.com>2018-10-24 11:23:05 +0300
committerBruno de Oliveira Abinader <bruno@mapbox.com>2018-10-25 16:23:40 +0300
commit55710cbb6799cc3802ef2dbb53d85134739cf83e (patch)
tree41626cbc18051d015d150403c2e0272b382d88b9 /include
parent8e2214129eb30e278c2d8fc39801f6570b6f02e9 (diff)
downloadqtlocation-mapboxgl-55710cbb6799cc3802ef2dbb53d85134739cf83e.tar.gz
[core] Added RendererState::has{Image,Layer,Source}
Diffstat (limited to 'include')
-rw-r--r--include/mbgl/renderer/renderer_state.hpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/include/mbgl/renderer/renderer_state.hpp b/include/mbgl/renderer/renderer_state.hpp
index 1b300c190b..27985ae996 100644
--- a/include/mbgl/renderer/renderer_state.hpp
+++ b/include/mbgl/renderer/renderer_state.hpp
@@ -8,7 +8,7 @@ namespace mbgl {
class UpdateParameters;
/**
- * RendererState acts as a Memento-like object that is able to extract data out of UpdateParameters (an opaque object
+ * RendererState acts as a Memento object that is able to extract data out of UpdateParameters (an opaque object
* from the public API perspective).
*/
class RendererState {
@@ -17,6 +17,14 @@ public:
// Obtains a CameraOptions out of a given UpdateParameters object.
static CameraOptions getCameraOptions(UpdateParameters&, const EdgeInsets& = {});
+ // Returns whether an image with the given ID exists from a given UpdateParamters object.
+ static bool hasImage(UpdateParameters&, const std::string& id);
+
+ // Returns whether a layer with the given ID exists from a given UpdateParamters object.
+ static bool hasLayer(UpdateParameters&, const std::string& id);
+
+ // Returns whether a source with the given ID exists from a given UpdateParamters object.
+ static bool hasSource(UpdateParameters&, const std::string& id);
};
} // namespace mbgl