summaryrefslogtreecommitdiff
path: root/include/mbgl/storage/offline.hpp
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2016-02-23 18:25:36 -0800
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-02-24 13:38:14 -0800
commit065cda83fab02aea85573d9c2d78e9121296582d (patch)
tree8fab316922a052496e67aa49d968224ffbbf0fca /include/mbgl/storage/offline.hpp
parent5cefaeb85716b21f2bbe57165a244844114b8dbe (diff)
downloadqtlocation-mapboxgl-065cda83fab02aea85573d9c2d78e9121296582d.tar.gz
[core] Limit total number of offline Mapbox tiles
Diffstat (limited to 'include/mbgl/storage/offline.hpp')
-rw-r--r--include/mbgl/storage/offline.hpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/include/mbgl/storage/offline.hpp b/include/mbgl/storage/offline.hpp
index 2bc286dbab..a3153adc28 100644
--- a/include/mbgl/storage/offline.hpp
+++ b/include/mbgl/storage/offline.hpp
@@ -150,6 +150,22 @@ public:
* re-executes the user-provided implementation on the main thread.
*/
virtual void responseError(Response::Error) {}
+
+ /*
+ * Implement this method to be notified when the limit on the number of Mapbox
+ * tiles stored for offline regions has been reached.
+ *
+ * Once the limit has been reached, the SDK will not download further offline
+ * tiles from Mapbox APIs until existing tiles have been removed. Contact your
+ * Mapbox sales representative to raise the limit.
+ *
+ * This limit does not apply to non-Mapbox tile sources.
+ *
+ * Note that this method will be executed on the database thread; it is the
+ * responsibility of the SDK bindings to wrap this object in an interface that
+ * re-executes the user-provided implementation on the main thread.
+ */
+ virtual void mapboxTileCountLimitExceeded(uint64_t /* limit */) {}
};
class OfflineRegion {