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_IO_THREAD_H_ | 5 #ifndef CHROME_BROWSER_IO_THREAD_H_ |
6 #define CHROME_BROWSER_IO_THREAD_H_ | 6 #define CHROME_BROWSER_IO_THREAD_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 18 matching lines...) Expand all Loading... |
29 | 29 |
30 class PrefProxyConfigTracker; | 30 class PrefProxyConfigTracker; |
31 class PrefService; | 31 class PrefService; |
32 class PrefRegistrySimple; | 32 class PrefRegistrySimple; |
33 class SystemURLRequestContextGetter; | 33 class SystemURLRequestContextGetter; |
34 | 34 |
35 namespace base { | 35 namespace base { |
36 class CommandLine; | 36 class CommandLine; |
37 } | 37 } |
38 | 38 |
39 #if defined(OS_ANDROID) | 39 #if defined(ANDROID_JAVA_UI) |
40 namespace chrome { | 40 namespace chrome { |
41 namespace android { | 41 namespace android { |
42 class ExternalDataUseObserver; | 42 class ExternalDataUseObserver; |
43 } | 43 } |
44 } | 44 } |
45 #endif // defined(OS_ANDROID) | 45 #endif // defined(ANDROID_JAVA_UI) |
46 | 46 |
47 namespace chrome_browser_net { | 47 namespace chrome_browser_net { |
48 class DnsProbeService; | 48 class DnsProbeService; |
49 } | 49 } |
50 | 50 |
51 namespace extensions { | 51 namespace extensions { |
52 class EventRouterForwarder; | 52 class EventRouterForwarder; |
53 } | 53 } |
54 | 54 |
55 namespace net { | 55 namespace net { |
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 void InitializeNetworkSessionParams(net::HttpNetworkSession::Params* params); | 259 void InitializeNetworkSessionParams(net::HttpNetworkSession::Params* params); |
260 | 260 |
261 base::TimeTicks creation_time() const; | 261 base::TimeTicks creation_time() const; |
262 | 262 |
263 data_usage::DataUseAggregator* data_use_aggregator() const; | 263 data_usage::DataUseAggregator* data_use_aggregator() const; |
264 | 264 |
265 // Returns true if QUIC should be enabled for data reduction proxy, either as | 265 // Returns true if QUIC should be enabled for data reduction proxy, either as |
266 // a result of a field trial or a command line flag. | 266 // a result of a field trial or a command line flag. |
267 static bool ShouldEnableQuicForDataReductionProxy(); | 267 static bool ShouldEnableQuicForDataReductionProxy(); |
268 | 268 |
269 #if defined(OS_ANDROID) | 269 #if defined(ANDROID_JAVA_UI) |
270 chrome::android::ExternalDataUseObserver* external_data_use_observer() const { | 270 chrome::android::ExternalDataUseObserver* external_data_use_observer() const { |
271 return external_data_use_observer_.get(); | 271 return external_data_use_observer_.get(); |
272 } | 272 } |
273 #endif // defined(OS_ANDROID) | 273 #endif // defined(ANDROID_JAVA_UI) |
274 | 274 |
275 private: | 275 private: |
276 // Map from name to value for all parameters associate with a field trial. | 276 // Map from name to value for all parameters associate with a field trial. |
277 typedef std::map<std::string, std::string> VariationParameters; | 277 typedef std::map<std::string, std::string> VariationParameters; |
278 | 278 |
279 // Provide SystemURLRequestContextGetter with access to | 279 // Provide SystemURLRequestContextGetter with access to |
280 // InitSystemRequestContext(). | 280 // InitSystemRequestContext(). |
281 friend class SystemURLRequestContextGetter; | 281 friend class SystemURLRequestContextGetter; |
282 | 282 |
283 friend class test::IOThreadPeer; | 283 friend class test::IOThreadPeer; |
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
529 // True if SPDY is disabled by policy. | 529 // True if SPDY is disabled by policy. |
530 bool is_spdy_disabled_by_policy_; | 530 bool is_spdy_disabled_by_policy_; |
531 | 531 |
532 // True if QUIC is allowed by policy. | 532 // True if QUIC is allowed by policy. |
533 bool is_quic_allowed_by_policy_; | 533 bool is_quic_allowed_by_policy_; |
534 | 534 |
535 // Global aggregator of data use. It must outlive the | 535 // Global aggregator of data use. It must outlive the |
536 // |system_network_delegate|. | 536 // |system_network_delegate|. |
537 scoped_ptr<data_usage::DataUseAggregator> data_use_aggregator_; | 537 scoped_ptr<data_usage::DataUseAggregator> data_use_aggregator_; |
538 // An external observer of data use. | 538 // An external observer of data use. |
539 #if defined(OS_ANDROID) | 539 #if defined(ANDROID_JAVA_UI) |
540 scoped_ptr<chrome::android::ExternalDataUseObserver> | 540 scoped_ptr<chrome::android::ExternalDataUseObserver> |
541 external_data_use_observer_; | 541 external_data_use_observer_; |
542 #endif // defined(OS_ANDROID) | 542 #endif // defined(ANDROID_JAVA_UI) |
543 | 543 |
544 const base::TimeTicks creation_time_; | 544 const base::TimeTicks creation_time_; |
545 | 545 |
546 base::WeakPtrFactory<IOThread> weak_factory_; | 546 base::WeakPtrFactory<IOThread> weak_factory_; |
547 | 547 |
548 DISALLOW_COPY_AND_ASSIGN(IOThread); | 548 DISALLOW_COPY_AND_ASSIGN(IOThread); |
549 }; | 549 }; |
550 | 550 |
551 #endif // CHROME_BROWSER_IO_THREAD_H_ | 551 #endif // CHROME_BROWSER_IO_THREAD_H_ |
OLD | NEW |