diff options
author | Asheem Mamoowala <asheem.mamoowala@mapbox.com> | 2018-08-21 17:41:22 -0700 |
---|---|---|
committer | Asheem Mamoowala <asheem.mamoowala@mapbox.com> | 2018-08-24 09:42:36 -0700 |
commit | 383b13c26c2603efd26536240aca715cbb8d531c (patch) | |
tree | f3d87ac216ee16480c0c90a341baee4873754a90 /include/mbgl/storage/default_file_source.hpp | |
parent | 7997c3f744b4e04c460fcf32cc96d3ebe09eeb67 (diff) | |
download | qtlocation-mapboxgl-383b13c26c2603efd26536240aca715cbb8d531c.tar.gz |
Enforce Offline tile limit when merging sideloaded databasesupstream/merge-offlinedb
Diffstat (limited to 'include/mbgl/storage/default_file_source.hpp')
-rw-r--r-- | include/mbgl/storage/default_file_source.hpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/include/mbgl/storage/default_file_source.hpp b/include/mbgl/storage/default_file_source.hpp index 942749fc00..929fb3d7c3 100644 --- a/include/mbgl/storage/default_file_source.hpp +++ b/include/mbgl/storage/default_file_source.hpp @@ -106,12 +106,18 @@ public: * executed on the database thread; it is the responsibility of the SDK bindings * to re-execute a user-provided callback on the main thread. * + * The secondary database may need to be upgraded to the latest schema. This is done + * in-place and requires write-access to `sideDatabasePath`; it is the + * responsibility of the SDK bindings to ensure that this path is writeable. + * * Only resources and tiles that belong to a region will be copied over. Identical * regions will be flattened into a single new region in the main database. * - * Note that the resulting new regions may not be in a completed status if the - * secondary database does not contain all the tiles or resources required by the - * region definition. + * Invokes the callback with a `MapboxOfflineTileCountExceededException` error if + * the merge operation would result in the offline tile count limit being exceeded. + * + * Merged regions may not be in a completed status if the secondary database + * does not contain all the tiles or resources required by the region definition. */ void mergeOfflineRegions(const std::string& sideDatabasePath, std::function<void (expected<OfflineRegions, std::exception_ptr>)>); |