| 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_LOADER_NAVIGATION_URL_LOADER_FACTORY_H_ | 5 #ifndef CONTENT_BROWSER_LOADER_NAVIGATION_URL_LOADER_FACTORY_H_ |
| 6 #define CONTENT_BROWSER_LOADER_NAVIGATION_URL_LOADER_FACTORY_H_ | 6 #define CONTENT_BROWSER_LOADER_NAVIGATION_URL_LOADER_FACTORY_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "content/browser/loader/navigation_url_loader.h" | 11 #include "content/browser/loader/navigation_url_loader.h" |
| 12 | 12 |
| 13 namespace content { | 13 namespace content { |
| 14 | 14 |
| 15 // NavigationURLLoader::Create uses the currently registered factory to create | 15 // NavigationURLLoader::Create uses the currently registered factory to create |
| 16 // the loader. This is intended for testing. | 16 // the loader. This is intended for testing. |
| 17 class NavigationURLLoaderFactory { | 17 class NavigationURLLoaderFactory { |
| 18 public: | 18 public: |
| 19 virtual std::unique_ptr<NavigationURLLoader> CreateLoader( | 19 virtual std::unique_ptr<NavigationURLLoader> CreateLoader( |
| 20 BrowserContext* browser_context, | 20 BrowserContext* browser_context, |
| 21 std::unique_ptr<NavigationRequestInfo> request_info, | 21 std::unique_ptr<NavigationRequestInfo> request_info, |
| 22 std::unique_ptr<NavigationUIData> navigation_ui_data, |
| 22 ServiceWorkerNavigationHandle* service_worker_handle, | 23 ServiceWorkerNavigationHandle* service_worker_handle, |
| 23 NavigationURLLoaderDelegate* delegate) = 0; | 24 NavigationURLLoaderDelegate* delegate) = 0; |
| 24 | 25 |
| 25 protected: | 26 protected: |
| 26 NavigationURLLoaderFactory() {} | 27 NavigationURLLoaderFactory() {} |
| 27 virtual ~NavigationURLLoaderFactory() {} | 28 virtual ~NavigationURLLoaderFactory() {} |
| 28 | 29 |
| 29 private: | 30 private: |
| 30 DISALLOW_COPY_AND_ASSIGN(NavigationURLLoaderFactory); | 31 DISALLOW_COPY_AND_ASSIGN(NavigationURLLoaderFactory); |
| 31 }; | 32 }; |
| 32 | 33 |
| 33 } // namespace content | 34 } // namespace content |
| 34 | 35 |
| 35 #endif // CONTENT_BROWSER_LOADER_NAVIGATION_URL_LOADER_FACTORY_H_ | 36 #endif // CONTENT_BROWSER_LOADER_NAVIGATION_URL_LOADER_FACTORY_H_ |
| OLD | NEW |