Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(285)

Unified Diff: components/image_fetcher/request_metadata.h

Issue 2749283002: components/image_fetcher: Add a from_http_cache flag to RequestMetadata (Closed)
Patch Set: test Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/image_fetcher/request_metadata.h
diff --git a/components/image_fetcher/request_metadata.h b/components/image_fetcher/request_metadata.h
index 6b41e2d3c3136efc7fb600b37a522685a751d4db..03963eeb687a7ea1328b8cc564b09adf614027ba 100644
--- a/components/image_fetcher/request_metadata.h
+++ b/components/image_fetcher/request_metadata.h
@@ -7,13 +7,23 @@
#include <string>
+#include "net/url_request/url_fetcher.h"
+
namespace image_fetcher {
// Metadata for a URL request.
struct RequestMetadata {
+ // Impossible http response code. Used to signal that no http response code
+ // was received.
+ enum ResponseCode {
+ RESPONSE_CODE_INVALID = net::URLFetcher::RESPONSE_CODE_INVALID
+ };
+
+ RequestMetadata();
+
std::string mime_type;
- // HTTP response code.
- int response_code;
+ int http_response_code;
+ bool from_http_cache;
};
bool operator==(const RequestMetadata& lhs, const RequestMetadata& rhs);
« no previous file with comments | « components/image_fetcher/image_data_fetcher_unittest.cc ('k') | components/image_fetcher/request_metadata.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698