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

Unified Diff: chrome/browser/profiles/profile_impl_io_data.h

Issue 2978443002: Make ProfileIOData use URLRequestContextBuilder (Closed)
Patch Set: ? Created 3 years, 5 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: chrome/browser/profiles/profile_impl_io_data.h
diff --git a/chrome/browser/profiles/profile_impl_io_data.h b/chrome/browser/profiles/profile_impl_io_data.h
index 6ba3a12e3b3f40a043f0273b5d8005850dee2817..00414364485ff1c1c94d88c023d5ba63e3d17af2 100644
--- a/chrome/browser/profiles/profile_impl_io_data.h
+++ b/chrome/browser/profiles/profile_impl_io_data.h
@@ -26,6 +26,9 @@ class DomainReliabilityMonitor;
namespace net {
class CookieStore;
class HttpServerPropertiesManager;
+struct ReportingPolicy;
+class ReportingService;
+class URLRequestContextBuilder;
} // namespace net
namespace storage {
@@ -161,11 +164,13 @@ class ProfileImplIOData : public ProfileIOData {
std::unique_ptr<ChromeNetworkDelegate> chrome_network_delegate)
const override;
- void InitializeInternal(
- ProfileParams* profile_params,
- content::ProtocolHandlerMap* protocol_handlers,
- content::URLRequestInterceptorScopedVector request_interceptors)
- const override;
+ void InitializeInternal(net::URLRequestContextBuilder* builder,
+ ProfileParams* profile_params,
+ content::ProtocolHandlerMap* protocol_handlers,
+ content::URLRequestInterceptorScopedVector
+ request_interceptors) const override;
+ void OnMainRequestContextCreated(
+ ProfileParams* profile_params) const override;
void InitializeExtensionsRequestContext(
ProfileParams* profile_params) const override;
net::URLRequestContext* InitializeAppRequestContext(
@@ -194,9 +199,17 @@ class ProfileImplIOData : public ProfileIOData {
const StoragePartitionDescriptor& partition_descriptor) const override;
chrome_browser_net::Predictor* GetPredictor() override;
+ // Returns a net::ReportingService, if reporting should be enabled. Otherwise,
+ // returns nullptr.
+ // TODO(mmenke): Remove once URLRequestContextBuilders are always used to
+ // create URLRequestContexts.
std::unique_ptr<net::ReportingService> MaybeCreateReportingService(
net::URLRequestContext* url_request_context) const;
+ // Returns a net::ReportingPolicy, if reporting should be enabled. Otherwise,
+ // returns nullptr.
+ static std::unique_ptr<net::ReportingPolicy> MaybeCreateReportingPolicy();
+
// Deletes all network related data since |time|. It deletes transport
// security state since |time| and also deletes HttpServerProperties data.
// Works asynchronously, however if the |completion| callback is non-null,

Powered by Google App Engine
This is Rietveld 408576698