OLD | NEW |
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 | 10 |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/callback_forward.h" | 12 #include "base/callback_forward.h" |
13 #include "base/files/file_path.h" | 13 #include "base/files/file_path.h" |
14 #include "base/memory/ref_counted.h" | 14 #include "base/memory/ref_counted.h" |
15 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
16 #include "base/memory/weak_ptr.h" | 16 #include "base/memory/weak_ptr.h" |
17 #include "base/prefs/pref_member.h" | 17 #include "base/prefs/pref_member.h" |
18 #include "base/synchronization/lock.h" | 18 #include "base/synchronization/lock.h" |
19 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" | 19 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" |
20 #include "chrome/browser/io_thread.h" | 20 #include "chrome/browser/io_thread.h" |
21 #include "chrome/browser/net/chrome_url_request_context.h" | 21 #include "chrome/browser/net/chrome_url_request_context.h" |
22 #include "chrome/browser/profiles/profile.h" | 22 #include "chrome/browser/profiles/profile.h" |
23 #include "chrome/browser/profiles/storage_partition_descriptor.h" | 23 #include "chrome/browser/profiles/storage_partition_descriptor.h" |
24 #include "chrome/common/content_settings_types.h" | 24 #include "chrome/common/content_settings_types.h" |
25 #include "components/data_reduction_proxy/browser/data_reduction_proxy_usage_sta
ts.h" | |
26 #include "content/public/browser/content_browser_client.h" | 25 #include "content/public/browser/content_browser_client.h" |
27 #include "content/public/browser/resource_context.h" | 26 #include "content/public/browser/resource_context.h" |
28 #include "net/cookies/cookie_monster.h" | 27 #include "net/cookies/cookie_monster.h" |
29 #include "net/http/http_cache.h" | 28 #include "net/http/http_cache.h" |
30 #include "net/http/http_network_session.h" | 29 #include "net/http/http_network_session.h" |
31 #include "net/url_request/url_request_job_factory.h" | 30 #include "net/url_request/url_request_job_factory.h" |
32 | 31 |
33 class ChromeHttpUserAgentSettings; | 32 class ChromeHttpUserAgentSettings; |
34 class ChromeNetworkDelegate; | 33 class ChromeNetworkDelegate; |
35 class CookieSettings; | 34 class CookieSettings; |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
334 prerender::PrerenderTracker* prerender_tracker; | 333 prerender::PrerenderTracker* prerender_tracker; |
335 }; | 334 }; |
336 | 335 |
337 explicit ProfileIOData(Profile::ProfileType profile_type); | 336 explicit ProfileIOData(Profile::ProfileType profile_type); |
338 | 337 |
339 static std::string GetSSLSessionCacheShard(); | 338 static std::string GetSSLSessionCacheShard(); |
340 | 339 |
341 void InitializeOnUIThread(Profile* profile); | 340 void InitializeOnUIThread(Profile* profile); |
342 void ApplyProfileParamsToContext(ChromeURLRequestContext* context) const; | 341 void ApplyProfileParamsToContext(ChromeURLRequestContext* context) const; |
343 | 342 |
344 #if defined(OS_ANDROID) | |
345 #if defined(SPDY_PROXY_AUTH_ORIGIN) | |
346 void SetDataReductionProxyUsageStatsOnIOThread(IOThread* io_thread, | |
347 Profile* profile); | |
348 void SetDataReductionProxyUsageStatsOnUIThread(Profile* profile, | |
349 data_reduction_proxy::DataReductionProxyUsageStats* usage_stats); | |
350 #endif | |
351 #endif | |
352 | |
353 scoped_ptr<net::URLRequestJobFactory> SetUpJobFactoryDefaults( | 343 scoped_ptr<net::URLRequestJobFactory> SetUpJobFactoryDefaults( |
354 scoped_ptr<net::URLRequestJobFactoryImpl> job_factory, | 344 scoped_ptr<net::URLRequestJobFactoryImpl> job_factory, |
355 content::URLRequestInterceptorScopedVector request_interceptors, | 345 content::URLRequestInterceptorScopedVector request_interceptors, |
356 scoped_ptr<ProtocolHandlerRegistry::JobInterceptorFactory> | 346 scoped_ptr<ProtocolHandlerRegistry::JobInterceptorFactory> |
357 protocol_handler_interceptor, | 347 protocol_handler_interceptor, |
358 net::NetworkDelegate* network_delegate, | 348 net::NetworkDelegate* network_delegate, |
359 net::FtpTransactionFactory* ftp_transaction_factory) const; | 349 net::FtpTransactionFactory* ftp_transaction_factory) const; |
360 | 350 |
361 // Called when the profile is destroyed. | 351 // Called when the profile is destroyed. |
362 void ShutdownOnUIThread(); | 352 void ShutdownOnUIThread(); |
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
616 | 606 |
617 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. | 607 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. |
618 bool initialized_on_UI_thread_; | 608 bool initialized_on_UI_thread_; |
619 | 609 |
620 const Profile::ProfileType profile_type_; | 610 const Profile::ProfileType profile_type_; |
621 | 611 |
622 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); | 612 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); |
623 }; | 613 }; |
624 | 614 |
625 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 615 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
OLD | NEW |