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

Side by Side Diff: chrome/browser/profiles/profile_io_data.h

Issue 684223003: Data Reduction Proxy Interstitials (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 1 month 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ 5 #ifndef CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_
6 #define CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ 6 #define CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/basictypes.h" 12 #include "base/basictypes.h"
13 #include "base/callback_forward.h" 13 #include "base/callback_forward.h"
14 #include "base/files/file_path.h" 14 #include "base/files/file_path.h"
15 #include "base/memory/ref_counted.h" 15 #include "base/memory/ref_counted.h"
16 #include "base/memory/scoped_ptr.h" 16 #include "base/memory/scoped_ptr.h"
17 #include "base/memory/weak_ptr.h" 17 #include "base/memory/weak_ptr.h"
18 #include "base/prefs/pref_member.h" 18 #include "base/prefs/pref_member.h"
19 #include "base/synchronization/lock.h" 19 #include "base/synchronization/lock.h"
20 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" 20 #include "chrome/browser/custom_handlers/protocol_handler_registry.h"
21 #include "chrome/browser/io_thread.h" 21 #include "chrome/browser/io_thread.h"
22 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_configurator. h" 22 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_configurator. h"
23 #include "chrome/browser/profiles/profile.h" 23 #include "chrome/browser/profiles/profile.h"
24 #include "chrome/browser/profiles/storage_partition_descriptor.h" 24 #include "chrome/browser/profiles/storage_partition_descriptor.h"
25 #include "components/content_settings/core/common/content_settings_types.h" 25 #include "components/content_settings/core/common/content_settings_types.h"
26 #include "components/data_reduction_proxy/content/data_reduction_proxy_ui_servic e.h"
26 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_auth _request_handler.h" 27 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_auth _request_handler.h"
27 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_stat istics_prefs.h" 28 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_stat istics_prefs.h"
28 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_usag e_stats.h" 29 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_usag e_stats.h"
29 #include "content/public/browser/content_browser_client.h" 30 #include "content/public/browser/content_browser_client.h"
30 #include "content/public/browser/resource_context.h" 31 #include "content/public/browser/resource_context.h"
31 #include "net/cookies/cookie_monster.h" 32 #include "net/cookies/cookie_monster.h"
32 #include "net/http/http_cache.h" 33 #include "net/http/http_cache.h"
33 #include "net/http/http_network_session.h" 34 #include "net/http/http_network_session.h"
34 #include "net/url_request/url_request_context.h" 35 #include "net/url_request/url_request_context.h"
35 #include "net/url_request/url_request_job_factory.h" 36 #include "net/url_request/url_request_job_factory.h"
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 content::ResourceContext::SaltCallback GetMediaDeviceIDSalt() const; 203 content::ResourceContext::SaltCallback GetMediaDeviceIDSalt() const;
203 204
204 DevToolsNetworkController* network_controller() const { 205 DevToolsNetworkController* network_controller() const {
205 return network_controller_.get(); 206 return network_controller_.get();
206 } 207 }
207 208
208 net::TransportSecurityState* transport_security_state() const { 209 net::TransportSecurityState* transport_security_state() const {
209 return transport_security_state_.get(); 210 return transport_security_state_.get();
210 } 211 }
211 212
213 data_reduction_proxy::DataReductionProxyParams* data_reduction_proxy_params()
bengr 2014/10/31 17:06:47 Can the pointer be const too?
megjablon 2014/12/11 23:32:04 Acknowledged.
214 const {
215 return data_reduction_proxy_params_.get();
216 }
217
218 data_reduction_proxy::DataReductionProxyUIService*
219 data_reduction_proxy_ui_service() const {
220 return data_reduction_proxy_ui_service_.get();
221 }
222
212 #if defined(OS_CHROMEOS) 223 #if defined(OS_CHROMEOS)
213 std::string username_hash() const { 224 std::string username_hash() const {
214 return username_hash_; 225 return username_hash_;
215 } 226 }
216 227
217 bool use_system_key_slot() const { return use_system_key_slot_; } 228 bool use_system_key_slot() const { return use_system_key_slot_; }
218 #endif 229 #endif
219 230
220 Profile::ProfileType profile_type() const { 231 Profile::ProfileType profile_type() const {
221 return profile_type_; 232 return profile_type_;
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 void ShutdownOnUIThread( 374 void ShutdownOnUIThread(
364 scoped_ptr<ChromeURLRequestContextGetterVector> context_getters); 375 scoped_ptr<ChromeURLRequestContextGetterVector> context_getters);
365 376
366 // A ChannelIDService object is created by a derived class of 377 // A ChannelIDService object is created by a derived class of
367 // ProfileIOData, and the derived class calls this method to set the 378 // ProfileIOData, and the derived class calls this method to set the
368 // channel_id_service_ member and transfers ownership to the base 379 // channel_id_service_ member and transfers ownership to the base
369 // class. 380 // class.
370 void set_channel_id_service( 381 void set_channel_id_service(
371 net::ChannelIDService* channel_id_service) const; 382 net::ChannelIDService* channel_id_service) const;
372 383
373 data_reduction_proxy::DataReductionProxyParams* data_reduction_proxy_params()
374 const {
375 return data_reduction_proxy_params_.get();
376 }
377
378 void set_data_reduction_proxy_params( 384 void set_data_reduction_proxy_params(
379 scoped_ptr<data_reduction_proxy::DataReductionProxyParams> 385 scoped_ptr<data_reduction_proxy::DataReductionProxyParams>
380 data_reduction_proxy_params) const { 386 data_reduction_proxy_params) const {
381 data_reduction_proxy_params_ = data_reduction_proxy_params.Pass(); 387 data_reduction_proxy_params_ = data_reduction_proxy_params.Pass();
382 } 388 }
383 389
384 data_reduction_proxy::DataReductionProxyUsageStats* 390 data_reduction_proxy::DataReductionProxyUsageStats*
385 data_reduction_proxy_usage_stats() const { 391 data_reduction_proxy_usage_stats() const {
386 return data_reduction_proxy_usage_stats_.get(); 392 return data_reduction_proxy_usage_stats_.get();
387 } 393 }
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 return data_reduction_proxy_auth_request_handler_.get(); 437 return data_reduction_proxy_auth_request_handler_.get();
432 } 438 }
433 439
434 void set_data_reduction_proxy_auth_request_handler( 440 void set_data_reduction_proxy_auth_request_handler(
435 scoped_ptr<data_reduction_proxy::DataReductionProxyAuthRequestHandler> 441 scoped_ptr<data_reduction_proxy::DataReductionProxyAuthRequestHandler>
436 data_reduction_proxy_auth_request_handler) const { 442 data_reduction_proxy_auth_request_handler) const {
437 data_reduction_proxy_auth_request_handler_ = 443 data_reduction_proxy_auth_request_handler_ =
438 data_reduction_proxy_auth_request_handler.Pass(); 444 data_reduction_proxy_auth_request_handler.Pass();
439 } 445 }
440 446
447 void set_data_reduction_proxy_ui_service(
448 scoped_ptr<data_reduction_proxy::DataReductionProxyUIService>
449 data_reduction_proxy_ui_service) const {
450 data_reduction_proxy_ui_service_ =
451 data_reduction_proxy_ui_service.Pass();
452 }
453
441 ChromeNetworkDelegate* network_delegate() const { 454 ChromeNetworkDelegate* network_delegate() const {
442 return network_delegate_.get(); 455 return network_delegate_.get();
443 } 456 }
444 457
445 net::FraudulentCertificateReporter* fraudulent_certificate_reporter() const { 458 net::FraudulentCertificateReporter* fraudulent_certificate_reporter() const {
446 return fraudulent_certificate_reporter_.get(); 459 return fraudulent_certificate_reporter_.get();
447 } 460 }
448 461
449 net::ProxyService* proxy_service() const { 462 net::ProxyService* proxy_service() const {
450 return proxy_service_.get(); 463 return proxy_service_.get();
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
646 data_reduction_proxy_params_; 659 data_reduction_proxy_params_;
647 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyUsageStats> 660 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyUsageStats>
648 data_reduction_proxy_usage_stats_; 661 data_reduction_proxy_usage_stats_;
649 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyStatisticsPrefs> 662 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyStatisticsPrefs>
650 data_reduction_proxy_statistics_prefs_; 663 data_reduction_proxy_statistics_prefs_;
651 mutable base::Callback<void(bool)> data_reduction_proxy_unavailable_callback_; 664 mutable base::Callback<void(bool)> data_reduction_proxy_unavailable_callback_;
652 mutable scoped_ptr<DataReductionProxyChromeConfigurator> 665 mutable scoped_ptr<DataReductionProxyChromeConfigurator>
653 data_reduction_proxy_chrome_configurator_; 666 data_reduction_proxy_chrome_configurator_;
654 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyAuthRequestHandler> 667 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyAuthRequestHandler>
655 data_reduction_proxy_auth_request_handler_; 668 data_reduction_proxy_auth_request_handler_;
669 mutable scoped_ptr<data_reduction_proxy::DataReductionProxyUIService>
670 data_reduction_proxy_ui_service_;
656 671
657 mutable scoped_ptr<ChromeNetworkDelegate> network_delegate_; 672 mutable scoped_ptr<ChromeNetworkDelegate> network_delegate_;
658 mutable scoped_ptr<net::FraudulentCertificateReporter> 673 mutable scoped_ptr<net::FraudulentCertificateReporter>
659 fraudulent_certificate_reporter_; 674 fraudulent_certificate_reporter_;
660 mutable scoped_ptr<net::ProxyService> proxy_service_; 675 mutable scoped_ptr<net::ProxyService> proxy_service_;
661 mutable scoped_ptr<net::TransportSecurityState> transport_security_state_; 676 mutable scoped_ptr<net::TransportSecurityState> transport_security_state_;
662 mutable scoped_ptr<net::HttpServerProperties> 677 mutable scoped_ptr<net::HttpServerProperties>
663 http_server_properties_; 678 http_server_properties_;
664 #if defined(OS_CHROMEOS) 679 #if defined(OS_CHROMEOS)
665 // Set to |cert_verifier_| if it references a PolicyCertVerifier. In that 680 // Set to |cert_verifier_| if it references a PolicyCertVerifier. In that
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 717
703 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. 718 // TODO(jhawkins): Remove once crbug.com/102004 is fixed.
704 bool initialized_on_UI_thread_; 719 bool initialized_on_UI_thread_;
705 720
706 const Profile::ProfileType profile_type_; 721 const Profile::ProfileType profile_type_;
707 722
708 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); 723 DISALLOW_COPY_AND_ASSIGN(ProfileIOData);
709 }; 724 };
710 725
711 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ 726 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698