OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_BROWSER_DEVTOOLS_PROTOCOL_NETWORK_HANDLER_H_ | 5 #ifndef CONTENT_BROWSER_DEVTOOLS_PROTOCOL_NETWORK_HANDLER_H_ |
6 #define CONTENT_BROWSER_DEVTOOLS_PROTOCOL_NETWORK_HANDLER_H_ | 6 #define CONTENT_BROWSER_DEVTOOLS_PROTOCOL_NETWORK_HANDLER_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "content/browser/devtools/protocol/devtools_domain_handler.h" |
9 #include "content/browser/devtools/protocol/network.h" | 10 #include "content/browser/devtools/protocol/network.h" |
10 #include "net/cookies/canonical_cookie.h" | 11 #include "net/cookies/canonical_cookie.h" |
11 | 12 |
12 namespace content { | 13 namespace content { |
13 | 14 |
14 class RenderFrameHostImpl; | 15 class RenderFrameHostImpl; |
15 | 16 |
16 namespace protocol { | 17 namespace protocol { |
17 | 18 |
18 class NetworkHandler : public Network::Backend { | 19 class NetworkHandler : public DevToolsDomainHandler, |
| 20 public Network::Backend { |
19 public: | 21 public: |
20 NetworkHandler(); | 22 NetworkHandler(); |
21 ~NetworkHandler() override; | 23 ~NetworkHandler() override; |
22 | 24 |
23 void SetRenderFrameHost(RenderFrameHostImpl* host); | 25 void Wire(UberDispatcher* dispatcher) override; |
24 void Wire(UberDispatcher*); | 26 void SetRenderFrameHost(RenderFrameHostImpl* host) override; |
25 | 27 |
26 Response Enable(Maybe<int> max_total_size, | 28 Response Enable(Maybe<int> max_total_size, |
27 Maybe<int> max_resource_size) override; | 29 Maybe<int> max_resource_size) override; |
28 Response Disable() override; | 30 Response Disable() override; |
29 | 31 |
30 Response ClearBrowserCache() override; | 32 Response ClearBrowserCache() override; |
31 Response ClearBrowserCookies() override; | 33 Response ClearBrowserCookies() override; |
32 | 34 |
33 void GetCookies(std::unique_ptr<GetCookiesCallback> callback) override; | 35 void GetCookies(std::unique_ptr<GetCookiesCallback> callback) override; |
34 void GetAllCookies(std::unique_ptr<GetAllCookiesCallback> callback) override; | 36 void GetAllCookies(std::unique_ptr<GetAllCookiesCallback> callback) override; |
(...skipping 23 matching lines...) Expand all Loading... |
58 bool enabled_; | 60 bool enabled_; |
59 std::string user_agent_; | 61 std::string user_agent_; |
60 | 62 |
61 DISALLOW_COPY_AND_ASSIGN(NetworkHandler); | 63 DISALLOW_COPY_AND_ASSIGN(NetworkHandler); |
62 }; | 64 }; |
63 | 65 |
64 } // namespace protocol | 66 } // namespace protocol |
65 } // namespace content | 67 } // namespace content |
66 | 68 |
67 #endif // CONTENT_BROWSER_DEVTOOLS_PROTOCOL_NETWORK_HANDLER_H_ | 69 #endif // CONTENT_BROWSER_DEVTOOLS_PROTOCOL_NETWORK_HANDLER_H_ |
OLD | NEW |