OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 COMPONENTS_OFFLINE_PAGES_STUB_OFFLINE_PAGE_MODEL_H_ | 5 #ifndef COMPONENTS_OFFLINE_PAGES_CORE_STUB_OFFLINE_PAGE_MODEL_H_ |
6 #define COMPONENTS_OFFLINE_PAGES_STUB_OFFLINE_PAGE_MODEL_H_ | 6 #define COMPONENTS_OFFLINE_PAGES_CORE_STUB_OFFLINE_PAGE_MODEL_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "components/keyed_service/core/keyed_service.h" | 12 #include "components/keyed_service/core/keyed_service.h" |
13 #include "components/offline_pages/client_policy_controller.h" | 13 #include "components/offline_pages/core/client_policy_controller.h" |
14 #include "components/offline_pages/offline_page_model.h" | 14 #include "components/offline_pages/core/offline_page_model.h" |
15 | 15 |
16 namespace offline_pages { | 16 namespace offline_pages { |
17 | 17 |
18 // Stub implementation of OfflinePageModel interface for testing. Besides using | 18 // Stub implementation of OfflinePageModel interface for testing. Besides using |
19 // as a stub for tests, it may also be subclassed to mock specific methods | 19 // as a stub for tests, it may also be subclassed to mock specific methods |
20 // needed for a set of tests. | 20 // needed for a set of tests. |
21 class StubOfflinePageModel : public OfflinePageModel, public KeyedService { | 21 class StubOfflinePageModel : public OfflinePageModel, public KeyedService { |
22 public: | 22 public: |
23 StubOfflinePageModel(); | 23 StubOfflinePageModel(); |
24 ~StubOfflinePageModel() override; | 24 ~StubOfflinePageModel() override; |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 bool is_loaded() const override; | 60 bool is_loaded() const override; |
61 OfflineEventLogger* GetLogger() override; | 61 OfflineEventLogger* GetLogger() override; |
62 | 62 |
63 private: | 63 private: |
64 ClientPolicyController policy_controller_; | 64 ClientPolicyController policy_controller_; |
65 std::vector<int64_t> offline_ids_; | 65 std::vector<int64_t> offline_ids_; |
66 }; | 66 }; |
67 | 67 |
68 } // namespace offline_pages | 68 } // namespace offline_pages |
69 | 69 |
70 #endif // COMPONENTS_OFFLINE_PAGES_STUB_OFFLINE_PAGE_MODEL_H_ | 70 #endif // COMPONENTS_OFFLINE_PAGES_CORE_STUB_OFFLINE_PAGE_MODEL_H_ |
OLD | NEW |