summaryrefslogtreecommitdiff
path: root/src/mbgl/storage/resource_options.cpp
diff options
context:
space:
mode:
authorBruno de Oliveira Abinader <bruno@mapbox.com>2019-03-22 21:15:00 +0200
committerBruno de Oliveira Abinader <bruno@mapbox.com>2019-03-22 22:02:28 +0200
commit7f734ea31b8b89ce7072ff3aaa305808ed346d1d (patch)
treeeebe292ac36bb09f3ec6d04d54bf45f07945cb40 /src/mbgl/storage/resource_options.cpp
parentdcd6efd5b5c806c524095500ae1d832765816f47 (diff)
downloadqtlocation-mapboxgl-upstream/revert-14189-options-unique_ptr.tar.gz
[core] Fix signature of fluent interface settersupstream/revert-14189-options-unique_ptr
Diffstat (limited to 'src/mbgl/storage/resource_options.cpp')
-rw-r--r--src/mbgl/storage/resource_options.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/mbgl/storage/resource_options.cpp b/src/mbgl/storage/resource_options.cpp
index dcd7f84f7e..600b535228 100644
--- a/src/mbgl/storage/resource_options.cpp
+++ b/src/mbgl/storage/resource_options.cpp
@@ -19,54 +19,54 @@ ResourceOptions::~ResourceOptions() = default;
ResourceOptions::ResourceOptions(ResourceOptions&&) = default;
ResourceOptions::ResourceOptions(const ResourceOptions& other) : impl_(std::make_unique<Impl>(*other.impl_)) {}
-ResourceOptions ResourceOptions::withAccessToken(std::string token) {
+ResourceOptions& ResourceOptions::withAccessToken(std::string token) {
impl_->accessToken = std::move(token);
- return std::move(*this);
+ return *this;
}
const std::string& ResourceOptions::accessToken() const {
return impl_->accessToken;
}
-ResourceOptions ResourceOptions::withBaseURL(std::string url) {
+ResourceOptions& ResourceOptions::withBaseURL(std::string url) {
impl_->baseURL = std::move(url);
- return std::move(*this);
+ return *this;
}
const std::string& ResourceOptions::baseURL() const {
return impl_->baseURL;
}
-ResourceOptions ResourceOptions::withCachePath(std::string path) {
+ResourceOptions& ResourceOptions::withCachePath(std::string path) {
impl_->cachePath = std::move(path);
- return std::move(*this);
+ return *this;
}
const std::string& ResourceOptions::cachePath() const {
return impl_->cachePath;
}
-ResourceOptions ResourceOptions::withAssetPath(std::string path) {
+ResourceOptions& ResourceOptions::withAssetPath(std::string path) {
impl_->assetPath = std::move(path);
- return std::move(*this);
+ return *this;
}
const std::string& ResourceOptions::assetPath() const {
return impl_->assetPath;
}
-ResourceOptions ResourceOptions::withMaximumCacheSize(uint64_t size) {
+ResourceOptions& ResourceOptions::withMaximumCacheSize(uint64_t size) {
impl_->maximumSize = size;
- return std::move(*this);
+ return *this;
}
uint64_t ResourceOptions::maximumCacheSize() const {
return impl_->maximumSize;
}
-ResourceOptions ResourceOptions::withPlatformContext(void* context) {
+ResourceOptions& ResourceOptions::withPlatformContext(void* context) {
impl_->platformContext = context;
- return std::move(*this);
+ return *this;
}
void* ResourceOptions::platformContext() const {