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

Side by Side Diff: blimp/engine/app/blimp_url_request_context_getter.h

Issue 2629743003: Remove all blimp engine code (Closed)
Patch Set: Use consistent comment style in //chrome Created 3 years, 11 months 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef BLIMP_ENGINE_APP_BLIMP_URL_REQUEST_CONTEXT_GETTER_H_
6 #define BLIMP_ENGINE_APP_BLIMP_URL_REQUEST_CONTEXT_GETTER_H_
7
8 #include <memory>
9
10 #include "base/files/file_path.h"
11 #include "base/macros.h"
12 #include "content/public/browser/browser_context.h"
13 #include "content/public/browser/content_browser_client.h"
14 #include "net/url_request/url_request_context_getter.h"
15
16 namespace base {
17 class SingleThreadTaskRunner;
18 }
19
20 namespace net {
21 class HostResolver;
22 class NetLog;
23 class ProxyConfigService;
24 }
25
26 namespace blimp {
27 namespace engine {
28
29 // The URLRequestContextGetter for Blimp "user" requests.
30 // System request context is handled in a separate class.
31 class BlimpURLRequestContextGetter : public net::URLRequestContextGetter {
32 public:
33 // The content of |protocol_handlers| is is swapped into the new instance.
34 BlimpURLRequestContextGetter(
35 bool ignore_certificate_errors,
36 const base::FilePath& base_path,
37 const scoped_refptr<base::SingleThreadTaskRunner>& io_loop_task_runner,
38 const scoped_refptr<base::SingleThreadTaskRunner>& file_loop_task_runner,
39 content::ProtocolHandlerMap* protocol_handlers,
40 content::URLRequestInterceptorScopedVector request_interceptors,
41 net::NetLog* net_log);
42
43 // net::URLRequestContextGetter implementation.
44 net::URLRequestContext* GetURLRequestContext() override;
45 scoped_refptr<base::SingleThreadTaskRunner> GetNetworkTaskRunner()
46 const override;
47
48 net::HostResolver* host_resolver();
49
50 private:
51 ~BlimpURLRequestContextGetter() override;
52
53 bool ignore_certificate_errors_;
54 base::FilePath base_path_;
55 scoped_refptr<base::SingleThreadTaskRunner> io_loop_task_runner_;
56 scoped_refptr<base::SingleThreadTaskRunner> file_loop_task_runner_;
57 net::NetLog* net_log_;
58
59 std::unique_ptr<net::ProxyConfigService> proxy_config_service_;
60 std::unique_ptr<net::URLRequestContext> url_request_context_;
61 content::ProtocolHandlerMap protocol_handlers_;
62 content::URLRequestInterceptorScopedVector request_interceptors_;
63
64 DISALLOW_COPY_AND_ASSIGN(BlimpURLRequestContextGetter);
65 };
66
67 } // namespace engine
68 } // namespace blimp
69
70 #endif // BLIMP_ENGINE_APP_BLIMP_URL_REQUEST_CONTEXT_GETTER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698