summaryrefslogtreecommitdiff
path: root/include/mbgl/storage/response.hpp
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2016-01-19 15:57:17 -0800
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-01-21 11:22:11 -0800
commit1c21d0fd4cd30cbf6c5b863fd0179b227c28bc0b (patch)
treedfb6b788285d2b28f7060138ae28734ece13942e /include/mbgl/storage/response.hpp
parentc33ed50c98c57ce2f2cf3b971bcf72c4208bf120 (diff)
downloadqtlocation-mapboxgl-1c21d0fd4cd30cbf6c5b863fd0179b227c28bc0b.tar.gz
[core] Use better types for modified / expires / etag
Diffstat (limited to 'include/mbgl/storage/response.hpp')
-rw-r--r--include/mbgl/storage/response.hpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/mbgl/storage/response.hpp b/include/mbgl/storage/response.hpp
index a7a200c53a..e81af710f7 100644
--- a/include/mbgl/storage/response.hpp
+++ b/include/mbgl/storage/response.hpp
@@ -2,6 +2,7 @@
#define MBGL_STORAGE_RESPONSE
#include <mbgl/util/chrono.hpp>
+#include <mbgl/util/optional.hpp>
#include <string>
#include <memory>
@@ -25,9 +26,9 @@ public:
// The actual data of the response. This is guaranteed to never be empty.
std::shared_ptr<const std::string> data;
- Seconds modified = Seconds::zero();
- Seconds expires = Seconds::zero();
- std::string etag;
+ optional<SystemTimePoint> modified;
+ optional<SystemTimePoint> expires;
+ optional<std::string> etag;
};
class Response::Error {