summaryrefslogtreecommitdiff
path: root/include/mbgl/storage
diff options
context:
space:
mode:
authorIvo van Dongen <info@ivovandongen.nl>2016-08-31 16:43:33 +0200
committerIvo van Dongen <info@ivovandongen.nl>2016-09-13 14:21:37 +0200
commit290bd07a92d7103c67f606c1423785069fc9b776 (patch)
tree00fa0a654830f3cf239932f266e311cab6ebeb59 /include/mbgl/storage
parentfdaf26b2c02afa6042876962f92b1eaf0ada19bb (diff)
downloadqtlocation-mapboxgl-290bd07a92d7103c67f606c1423785069fc9b776.tar.gz
[core] OnlineFileSource - rate limit
Diffstat (limited to 'include/mbgl/storage')
-rw-r--r--include/mbgl/storage/response.hpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/mbgl/storage/response.hpp b/include/mbgl/storage/response.hpp
index 4dc3f36681..448423c1cb 100644
--- a/include/mbgl/storage/response.hpp
+++ b/include/mbgl/storage/response.hpp
@@ -2,6 +2,7 @@
#include <mbgl/util/chrono.hpp>
#include <mbgl/util/optional.hpp>
+#include <mbgl/util/variant.hpp>
#include <string>
#include <memory>
@@ -45,15 +46,18 @@ public:
NotFound = 2,
Server = 3,
Connection = 4,
+ RateLimit = 5,
Other = 6,
} reason = Reason::Other;
// An error message from the request handler, e.g. a server message or a system message
// informing the user about the reason for the failure.
std::string message;
+
+ optional<Timestamp> retryAfter;
public:
- Error(Reason, std::string = "");
+ Error(Reason, std::string = "", optional<Timestamp> = {});
};
std::ostream& operator<<(std::ostream&, Response::Error::Reason);