summaryrefslogtreecommitdiff
path: root/include/mbgl
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2020-04-15 17:24:04 +0300
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2020-04-22 19:21:56 +0300
commiteac6bdff16af09f8b3fc2f6d4a5bb781862b0f18 (patch)
tree80c8d1f31199b3e1be8e9fbc51eb31ca8398fbe6 /include/mbgl
parent7af1a175a3da717c7171b234d1968e567f5673eb (diff)
downloadqtlocation-mapboxgl-eac6bdff16af09f8b3fc2f6d4a5bb781862b0f18.tar.gz
[core] Add style::Source::setVolatile()/isVolatile() API
Diffstat (limited to 'include/mbgl')
-rw-r--r--include/mbgl/style/source.hpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/mbgl/style/source.hpp b/include/mbgl/style/source.hpp
index a1650ad06a..e6208294ca 100644
--- a/include/mbgl/style/source.hpp
+++ b/include/mbgl/style/source.hpp
@@ -66,12 +66,14 @@ public:
std::string getID() const;
optional<std::string> getAttribution() const;
+ // The data from the volatile sources are not stored in a persistent storage.
+ bool isVolatile() const noexcept;
+ void setVolatile(bool) noexcept;
+
// Private implementation
class Impl;
Immutable<Impl> baseImpl;
- Source(Immutable<Impl>);
-
void setObserver(SourceObserver*);
SourceObserver* observer = nullptr;
@@ -114,6 +116,7 @@ public:
virtual mapbox::base::WeakPtr<Source> makeWeakPtr() = 0;
protected:
+ explicit Source(Immutable<Impl>);
virtual Mutable<Impl> createMutable() const noexcept = 0;
};