summaryrefslogtreecommitdiff
path: root/src/mbgl/util/mapbox.hpp
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2016-01-29 17:49:22 -0800
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-02-10 15:40:20 -0800
commit025375ad0b365a06e0742b92fecc9bc538b5a6e0 (patch)
treed94054813001e7b64c57d09651a47084064f9372 /src/mbgl/util/mapbox.hpp
parentdbb8e58aea00a84716aafa6887b50c0186169f9e (diff)
downloadqtlocation-mapboxgl-025375ad0b365a06e0742b92fecc9bc538b5a6e0.tar.gz
[core] Cache with mapbox:// tile URLs
Diffstat (limited to 'src/mbgl/util/mapbox.hpp')
-rw-r--r--src/mbgl/util/mapbox.hpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/mbgl/util/mapbox.hpp b/src/mbgl/util/mapbox.hpp
index 3c44d704c7..c03916ff63 100644
--- a/src/mbgl/util/mapbox.hpp
+++ b/src/mbgl/util/mapbox.hpp
@@ -14,13 +14,10 @@ std::string normalizeSourceURL(const std::string& url, const std::string& access
std::string normalizeStyleURL(const std::string& url, const std::string& accessToken);
std::string normalizeSpriteURL(const std::string& url, const std::string& accessToken);
std::string normalizeGlyphsURL(const std::string& url, const std::string& accessToken);
-std::string normalizeRasterTileURL(const std::string& url);
+std::string normalizeTileURL(const std::string& url, const std::string& accessToken);
-// Canonicalizes Mapbox URLs by removing [a-d] subdomain prefixes, access tokens, and protocol.
-// Note that this is close, but not exactly the reverse operation as above, as this retains certain
-// information, such as the API version. It is used to cache resources retrieved from the URL, that
-// sometimes have multiple valid URLs.
-std::string canonicalURL(const std::string &url);
+// Return a "mapbox://tiles/..." URL (suitable for normalizeTileURL) for the given Mapbox tile URL.
+std::string canonicalizeTileURL(const std::string& url, SourceType);
} // namespace mapbox
} // namespace util