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 CONTENT_SHELL_SHELL_URL_REQUEST_CONTEXT_GETTER_H_ | 5 #ifndef CONTENT_SHELL_SHELL_URL_REQUEST_CONTEXT_GETTER_H_ |
6 #define CONTENT_SHELL_SHELL_URL_REQUEST_CONTEXT_GETTER_H_ | 6 #define CONTENT_SHELL_SHELL_URL_REQUEST_CONTEXT_GETTER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
(...skipping 11 matching lines...) Expand all Loading... |
22 } | 22 } |
23 | 23 |
24 namespace content { | 24 namespace content { |
25 | 25 |
26 class ShellURLRequestContextGetter : public net::URLRequestContextGetter { | 26 class ShellURLRequestContextGetter : public net::URLRequestContextGetter { |
27 public: | 27 public: |
28 ShellURLRequestContextGetter( | 28 ShellURLRequestContextGetter( |
29 const FilePath& base_path, | 29 const FilePath& base_path, |
30 MessageLoop* io_loop, | 30 MessageLoop* io_loop, |
31 MessageLoop* file_loop); | 31 MessageLoop* file_loop); |
32 virtual ~ShellURLRequestContextGetter(); | |
33 | 32 |
34 // net::URLRequestContextGetter implementation. | 33 // net::URLRequestContextGetter implementation. |
35 virtual net::URLRequestContext* GetURLRequestContext() OVERRIDE; | 34 virtual net::URLRequestContext* GetURLRequestContext() OVERRIDE; |
36 virtual scoped_refptr<base::MessageLoopProxy> | 35 virtual scoped_refptr<base::MessageLoopProxy> |
37 GetIOMessageLoopProxy() const OVERRIDE; | 36 GetIOMessageLoopProxy() const OVERRIDE; |
38 | 37 |
39 net::HostResolver* host_resolver(); | 38 net::HostResolver* host_resolver(); |
40 | 39 |
| 40 protected: |
| 41 virtual ~ShellURLRequestContextGetter(); |
| 42 |
41 private: | 43 private: |
42 FilePath base_path_; | 44 FilePath base_path_; |
43 MessageLoop* io_loop_; | 45 MessageLoop* io_loop_; |
44 MessageLoop* file_loop_; | 46 MessageLoop* file_loop_; |
45 | 47 |
46 scoped_ptr<net::ProxyConfigService> proxy_config_service_; | 48 scoped_ptr<net::ProxyConfigService> proxy_config_service_; |
47 | 49 |
48 scoped_refptr<net::URLRequestContext> url_request_context_; | 50 scoped_refptr<net::URLRequestContext> url_request_context_; |
49 scoped_ptr<net::URLRequestContextStorage> storage_; | 51 scoped_ptr<net::URLRequestContextStorage> storage_; |
50 scoped_ptr<net::NetworkDelegate> network_delegate_; | 52 scoped_ptr<net::NetworkDelegate> network_delegate_; |
51 | 53 |
52 DISALLOW_COPY_AND_ASSIGN(ShellURLRequestContextGetter); | 54 DISALLOW_COPY_AND_ASSIGN(ShellURLRequestContextGetter); |
53 }; | 55 }; |
54 | 56 |
55 } // namespace content | 57 } // namespace content |
56 | 58 |
57 #endif // CONTENT_SHELL_SHELL_URL_REQUEST_CONTEXT_GETTER_H_ | 59 #endif // CONTENT_SHELL_SHELL_URL_REQUEST_CONTEXT_GETTER_H_ |
OLD | NEW |