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 <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
57 class URLRequestContext; | 57 class URLRequestContext; |
58 class URLRequestContextGetter; | 58 class URLRequestContextGetter; |
59 class URLRequestThrottlerManager; | 59 class URLRequestThrottlerManager; |
60 class URLSecurityManager; | 60 class URLSecurityManager; |
61 } // namespace net | 61 } // namespace net |
62 | 62 |
63 namespace policy { | 63 namespace policy { |
64 class PolicyService; | 64 class PolicyService; |
65 } // namespace policy | 65 } // namespace policy |
66 | 66 |
67 namespace v8 { | |
68 class Isolate; | |
69 } // namespace v8 | |
70 | |
67 // Contains state associated with, initialized and cleaned up on, and | 71 // Contains state associated with, initialized and cleaned up on, and |
68 // primarily used on, the IO thread. | 72 // primarily used on, the IO thread. |
69 // | 73 // |
70 // If you are looking to interact with the IO thread (e.g. post tasks | 74 // If you are looking to interact with the IO thread (e.g. post tasks |
71 // to it or check if it is the current thread), see | 75 // to it or check if it is the current thread), see |
72 // content::BrowserThread. | 76 // content::BrowserThread. |
73 class IOThread : public content::BrowserThreadDelegate { | 77 class IOThread : public content::BrowserThreadDelegate { |
74 public: | 78 public: |
75 struct Globals { | 79 struct Globals { |
76 template <typename T> | 80 template <typename T> |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
158 Optional<bool> enable_spdy_ip_pooling; | 162 Optional<bool> enable_spdy_ip_pooling; |
159 Optional<bool> enable_spdy_credential_frames; | 163 Optional<bool> enable_spdy_credential_frames; |
160 Optional<bool> enable_spdy_compression; | 164 Optional<bool> enable_spdy_compression; |
161 Optional<bool> enable_spdy_ping_based_connection_checking; | 165 Optional<bool> enable_spdy_ping_based_connection_checking; |
162 Optional<net::NextProto> spdy_default_protocol; | 166 Optional<net::NextProto> spdy_default_protocol; |
163 Optional<uint16> origin_port_to_force_quic_on; | 167 Optional<uint16> origin_port_to_force_quic_on; |
164 // NetErrorTabHelper uses |dns_probe_service| to send DNS probes when a | 168 // NetErrorTabHelper uses |dns_probe_service| to send DNS probes when a |
165 // main frame load fails with a DNS error in order to provide more useful | 169 // main frame load fails with a DNS error in order to provide more useful |
166 // information to the renderer so it can show a more specific error page. | 170 // information to the renderer so it can show a more specific error page. |
167 scoped_ptr<chrome_browser_net::DnsProbeService> dns_probe_service; | 171 scoped_ptr<chrome_browser_net::DnsProbeService> dns_probe_service; |
172 // The v8 default Isolate for the main thread. | |
jochen (gone - plz use gerrit)
2013/01/18 13:29:07
the comment is a bit misleading, since we'll use i
Sven Panne
2013/01/18 14:27:33
OK, it is v8's default Isolate, retrieved *from* t
| |
173 v8::Isolate* v8_default_isolate; | |
168 }; | 174 }; |
169 | 175 |
170 // |net_log| must either outlive the IOThread or be NULL. | 176 // |net_log| must either outlive the IOThread or be NULL. |
171 IOThread(PrefServiceSimple* local_state, | 177 IOThread(PrefServiceSimple* local_state, |
172 policy::PolicyService* policy_service, | 178 policy::PolicyService* policy_service, |
173 ChromeNetLog* net_log, | 179 ChromeNetLog* net_log, |
174 extensions::EventRouterForwarder* extension_event_router_forwarder); | 180 extensions::EventRouterForwarder* extension_event_router_forwarder); |
175 | 181 |
176 virtual ~IOThread(); | 182 virtual ~IOThread(); |
177 | 183 |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
293 scoped_refptr<net::URLRequestContextGetter> | 299 scoped_refptr<net::URLRequestContextGetter> |
294 system_url_request_context_getter_; | 300 system_url_request_context_getter_; |
295 | 301 |
296 net::SdchManager* sdch_manager_; | 302 net::SdchManager* sdch_manager_; |
297 | 303 |
298 // True if SPDY is disabled by policy. | 304 // True if SPDY is disabled by policy. |
299 bool is_spdy_disabled_by_policy_; | 305 bool is_spdy_disabled_by_policy_; |
300 | 306 |
301 base::WeakPtrFactory<IOThread> weak_factory_; | 307 base::WeakPtrFactory<IOThread> weak_factory_; |
302 | 308 |
309 v8::Isolate* v8_default_isolate_; | |
310 | |
303 DISALLOW_COPY_AND_ASSIGN(IOThread); | 311 DISALLOW_COPY_AND_ASSIGN(IOThread); |
304 }; | 312 }; |
305 | 313 |
306 #endif // CHROME_BROWSER_IO_THREAD_H_ | 314 #endif // CHROME_BROWSER_IO_THREAD_H_ |
OLD | NEW |