summaryrefslogtreecommitdiff
path: root/include/mbgl/storage/default_file_source.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/mbgl/storage/default_file_source.hpp')
-rw-r--r--include/mbgl/storage/default_file_source.hpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/include/mbgl/storage/default_file_source.hpp b/include/mbgl/storage/default_file_source.hpp
index e048d82af2..942749fc00 100644
--- a/include/mbgl/storage/default_file_source.hpp
+++ b/include/mbgl/storage/default_file_source.hpp
@@ -100,6 +100,23 @@ public:
std::function<void (expected<OfflineRegionStatus, std::exception_ptr>)>) const;
/*
+ * Merge offline regions from a secondary database into the main offline database.
+ *
+ * When the database merge is completed, the provided callback will be
+ * executed on the database thread; it is the responsibility of the SDK bindings
+ * to re-execute a user-provided callback on the main thread.
+ *
+ * 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.
+ */
+ void mergeOfflineRegions(const std::string& sideDatabasePath,
+ std::function<void (expected<OfflineRegions, std::exception_ptr>)>);
+
+ /*
* Remove an offline region from the database and perform any resources evictions
* necessary as a result.
*