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_BACKGROUND_OFFLINER_FACTORY_H_ | 5 #ifndef COMPONENTS_OFFLINE_PAGES_CORE_BACKGROUND_OFFLINER_FACTORY_H_ |
6 #define COMPONENTS_OFFLINE_PAGES_BACKGROUND_OFFLINER_FACTORY_H_ | 6 #define COMPONENTS_OFFLINE_PAGES_CORE_BACKGROUND_OFFLINER_FACTORY_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 | 9 |
10 namespace offline_pages { | 10 namespace offline_pages { |
11 | 11 |
12 class OfflinerPolicy; | 12 class OfflinerPolicy; |
13 class Offliner; | 13 class Offliner; |
14 | 14 |
15 // An interface to a factory which can create a background offliner. | 15 // An interface to a factory which can create a background offliner. |
16 // The returned factory is owned by the offliner, which is allowed to cache the | 16 // The returned factory is owned by the offliner, which is allowed to cache the |
17 // factory and return it again later. | 17 // factory and return it again later. |
18 class OfflinerFactory { | 18 class OfflinerFactory { |
19 public: | 19 public: |
20 OfflinerFactory() {} | 20 OfflinerFactory() {} |
21 virtual ~OfflinerFactory() {} | 21 virtual ~OfflinerFactory() {} |
22 | 22 |
23 virtual Offliner* GetOffliner(const OfflinerPolicy* policy) = 0; | 23 virtual Offliner* GetOffliner(const OfflinerPolicy* policy) = 0; |
24 | 24 |
25 private: | 25 private: |
26 DISALLOW_COPY_AND_ASSIGN(OfflinerFactory); | 26 DISALLOW_COPY_AND_ASSIGN(OfflinerFactory); |
27 }; | 27 }; |
28 | 28 |
29 } // namespace offline_pages | 29 } // namespace offline_pages |
30 | 30 |
31 #endif // COMPONENTS_OFFLINE_PAGES_BACKGROUND_OFFLINER_FACTORY_H_ | 31 #endif // COMPONENTS_OFFLINE_PAGES_CORE_BACKGROUND_OFFLINER_FACTORY_H_ |
OLD | NEW |