OLD | NEW |
---|---|
(Empty) | |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_FACTORY_H_ | |
6 #define CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_FACTORY_H_ | |
7 | |
8 #include "base/memory/scoped_ptr.h" | |
9 #include "content/browser/loader/navigation_url_loader_factory.h" | |
10 | |
11 namespace content { | |
12 | |
13 class NavigationURLLoader; | |
14 | |
15 // PlzNavigate | |
16 // Manages creation of the NavigationURLLoaders; when registered, all created | |
17 // NavigationURLLoaderss will be TestNavigationURLLoaderss. This automatically | |
18 // registers itself when it goes in scope, and unregisters itself when it goes | |
19 // out of scope. Since you can't have more than one factory registered at a | |
20 // time, you can only have one of these objects at a time. | |
21 class TestNavigationURLLoaderFactory : public NavigationURLLoaderFactory { | |
22 public: | |
23 TestNavigationURLLoaderFactory(); | |
24 ~TestNavigationURLLoaderFactory() override; | |
25 | |
26 protected: | |
nasko
2014/11/15 00:32:51
Why protected?
clamy
2014/11/17 12:51:13
I followed TestRenderFrameHostFactory which had it
| |
27 // RenderFrameHostFactory implementation. | |
carlosk
2014/11/17 10:46:56
s/RenderFrameHostFactory/NavigationURLLoaderFactor
clamy
2014/11/18 12:33:22
Done.
| |
28 scoped_ptr<NavigationURLLoader> CreateLoader( | |
29 BrowserContext* browser_context, | |
30 int64 frame_tree_node_id, | |
31 const CommonNavigationParams& common_params, | |
32 scoped_ptr<NavigationRequestInfo> request_info, | |
33 ResourceRequestBody* request_body, | |
34 NavigationURLLoaderDelegate* delegate) override; | |
35 | |
36 private: | |
37 DISALLOW_COPY_AND_ASSIGN(TestNavigationURLLoaderFactory); | |
38 }; | |
39 | |
40 } // namespace content | |
41 | |
42 #endif // CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_FACTORY_H_ | |
OLD | NEW |