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

Side by Side Diff: content/public/common/resource_response_info.h

Issue 2484633004: Change Lo-Fi bool to bitmask to support multiple Previews types (Closed)
Patch Set: fix ContentResourceProviderTest Created 3 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_INFO_H_ 5 #ifndef CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_INFO_H_
6 #define CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_INFO_H_ 6 #define CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_INFO_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
11 11
12 #include "base/files/file_path.h" 12 #include "base/files/file_path.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/time/time.h" 14 #include "base/time/time.h"
15 #include "content/common/content_export.h" 15 #include "content/common/content_export.h"
16 #include "content/public/common/previews_state.h"
16 #include "content/public/common/resource_devtools_info.h" 17 #include "content/public/common/resource_devtools_info.h"
17 #include "net/base/host_port_pair.h" 18 #include "net/base/host_port_pair.h"
18 #include "net/base/load_timing_info.h" 19 #include "net/base/load_timing_info.h"
19 #include "net/cert/signed_certificate_timestamp_and_status.h" 20 #include "net/cert/signed_certificate_timestamp_and_status.h"
20 #include "net/http/http_response_headers.h" 21 #include "net/http/http_response_headers.h"
21 #include "net/http/http_response_info.h" 22 #include "net/http/http_response_info.h"
22 #include "net/nqe/effective_connection_type.h" 23 #include "net/nqe/effective_connection_type.h"
23 #include "third_party/WebKit/public/platform/modules/serviceworker/WebServiceWor kerResponseType.h" 24 #include "third_party/WebKit/public/platform/modules/serviceworker/WebServiceWor kerResponseType.h"
24 #include "url/gurl.h" 25 #include "url/gurl.h"
25 26
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 base::TimeTicks service_worker_ready_time; 135 base::TimeTicks service_worker_ready_time;
135 136
136 // True when the response is served from the CacheStorage via the 137 // True when the response is served from the CacheStorage via the
137 // ServiceWorker. 138 // ServiceWorker.
138 bool is_in_cache_storage = false; 139 bool is_in_cache_storage = false;
139 140
140 // The cache name of the CacheStorage from where the response is served via 141 // The cache name of the CacheStorage from where the response is served via
141 // the ServiceWorker. Empty if the response isn't from the CacheStorage. 142 // the ServiceWorker. Empty if the response isn't from the CacheStorage.
142 std::string cache_storage_cache_name; 143 std::string cache_storage_cache_name;
143 144
144 // Whether or not the request was for a LoFi version of the resource. 145 // A bitmask of potentially several Previews optimizations that the resource
145 bool is_using_lofi; 146 // could have requested.
147 PreviewsState previews_state;
146 148
147 // Effective connection type when the resource was fetched. This is populated 149 // Effective connection type when the resource was fetched. This is populated
148 // only for responses that correspond to main frame requests. 150 // only for responses that correspond to main frame requests.
149 net::EffectiveConnectionType effective_connection_type; 151 net::EffectiveConnectionType effective_connection_type;
150 152
151 // DER-encoded X509Certificate certificate chain. Only present if the renderer 153 // DER-encoded X509Certificate certificate chain. Only present if the renderer
152 // process set report_raw_headers to true. 154 // process set report_raw_headers to true.
153 std::vector<std::string> certificate; 155 std::vector<std::string> certificate;
154 156
155 // Bitmask of status info of the SSL certificate. See cert_status_flags.h for 157 // Bitmask of status info of the SSL certificate. See cert_status_flags.h for
(...skipping 18 matching lines...) Expand all
174 net::SignedCertificateTimestampAndStatusList signed_certificate_timestamps; 176 net::SignedCertificateTimestampAndStatusList signed_certificate_timestamps;
175 177
176 // In case this is a CORS response fetched by a ServiceWorker, this is the 178 // In case this is a CORS response fetched by a ServiceWorker, this is the
177 // set of headers that should be exposed. 179 // set of headers that should be exposed.
178 std::vector<std::string> cors_exposed_header_names; 180 std::vector<std::string> cors_exposed_header_names;
179 }; 181 };
180 182
181 } // namespace content 183 } // namespace content
182 184
183 #endif // CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_INFO_H_ 185 #endif // CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_INFO_H_
OLDNEW
« no previous file with comments | « content/public/common/resource_response.cc ('k') | content/public/common/resource_response_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698