summaryrefslogtreecommitdiff
path: root/lib/httpserver/HTTPResponse.h
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2015-08-15 10:58:10 +0000
committerChris Wilson <chris+github@qwirx.com>2015-08-15 10:58:10 +0000
commit03c4946547d39d4d3c4f32878c47bbd701c6f690 (patch)
tree43180ec516f6afc81c215bb2cb120e254b0cc1e5 /lib/httpserver/HTTPResponse.h
parentfeade829d345bd6e34f39dfc32498696e6f588a1 (diff)
Add configurable timeouts and HEAD request support to S3 client.
Allow getting the Content-Length of an HTTPResponse object.
Diffstat (limited to 'lib/httpserver/HTTPResponse.h')
-rw-r--r--lib/httpserver/HTTPResponse.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/httpserver/HTTPResponse.h b/lib/httpserver/HTTPResponse.h
index 978fa91e..7911f8b5 100644
--- a/lib/httpserver/HTTPResponse.h
+++ b/lib/httpserver/HTTPResponse.h
@@ -66,6 +66,7 @@ public:
int GetResponseCode() const { return mResponseCode; }
void SetContentType(const char *ContentType);
const std::string& GetContentType() { return mContentType; }
+ int64_t GetContentLength() { return mContentLength; }
void SetAsRedirect(const char *RedirectTo, bool IsLocalURI = true);
void SetAsNotFound(const char *URI);
@@ -164,7 +165,7 @@ private:
bool mKeepAlive;
std::string mContentType;
std::vector<Header> mExtraHeaders;
- int mContentLength; // only used when reading response from stream
+ int64_t mContentLength; // only used when reading response from stream
IOStream* mpStreamToSendTo; // nonzero only when constructed with a stream
static std::string msDefaultURIPrefix;