OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 // InternalComponentsFactory exists so that tests can override creation of | 5 // InternalComponentsFactory exists so that tests can override creation of |
6 // components used by the SyncManager that are not exposed across the sync | 6 // components used by the SyncManager that are not exposed across the sync |
7 // API boundary. | 7 // API boundary. |
8 | 8 |
9 #ifndef SYNC_INTERNAL_API_PUBLIC_INTERNAL_COMPONENTS_FACTORY_H_ | 9 #ifndef SYNC_INTERNAL_API_PUBLIC_INTERNAL_COMPONENTS_FACTORY_H_ |
10 #define SYNC_INTERNAL_API_PUBLIC_INTERNAL_COMPONENTS_FACTORY_H_ | 10 #define SYNC_INTERNAL_API_PUBLIC_INTERNAL_COMPONENTS_FACTORY_H_ |
11 | 11 |
12 #include <string> | 12 #include <string> |
13 #include <vector> | 13 #include <vector> |
14 | 14 |
15 #include "base/files/file_path.h" | 15 #include "base/files/file_path.h" |
16 #include "sync/base/sync_export.h" | 16 #include "sync/base/sync_export.h" |
17 #include "sync/internal_api/public/engine/model_safe_worker.h" | 17 #include "sync/internal_api/public/engine/model_safe_worker.h" |
18 | 18 |
19 namespace syncer { | 19 namespace syncer { |
20 | 20 |
21 class CancelationSignal; | 21 class CancelationSignal; |
22 class ExtensionsActivity; | 22 class ExtensionsActivity; |
23 class ModelTypeRegistry; | 23 class ModelTypeRegistry; |
24 class ServerConnectionManager; | 24 class ServerConnectionManager; |
25 class SyncEngineEventListener; | 25 class SyncEngineEventListener; |
26 class SyncScheduler; | 26 class SyncScheduler; |
27 class TrafficRecorder; | |
28 | 27 |
29 namespace sessions { | 28 namespace sessions { |
30 class DebugInfoGetter; | 29 class DebugInfoGetter; |
31 class SyncSessionContext; | 30 class SyncSessionContext; |
32 } | 31 } |
33 | 32 |
34 namespace syncable { | 33 namespace syncable { |
35 class Directory; | 34 class Directory; |
36 class DirectoryBackingStore; | 35 class DirectoryBackingStore; |
37 } | 36 } |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 const std::string& name, | 78 const std::string& name, |
80 sessions::SyncSessionContext* context, | 79 sessions::SyncSessionContext* context, |
81 CancelationSignal* cancelation_signal) = 0; | 80 CancelationSignal* cancelation_signal) = 0; |
82 | 81 |
83 virtual scoped_ptr<sessions::SyncSessionContext> BuildContext( | 82 virtual scoped_ptr<sessions::SyncSessionContext> BuildContext( |
84 ServerConnectionManager* connection_manager, | 83 ServerConnectionManager* connection_manager, |
85 syncable::Directory* directory, | 84 syncable::Directory* directory, |
86 ExtensionsActivity* extensions_activity, | 85 ExtensionsActivity* extensions_activity, |
87 const std::vector<SyncEngineEventListener*>& listeners, | 86 const std::vector<SyncEngineEventListener*>& listeners, |
88 sessions::DebugInfoGetter* debug_info_getter, | 87 sessions::DebugInfoGetter* debug_info_getter, |
89 TrafficRecorder* traffic_recorder, | |
90 ModelTypeRegistry* model_type_registry, | 88 ModelTypeRegistry* model_type_registry, |
91 const std::string& invalidator_client_id) = 0; | 89 const std::string& invalidator_client_id) = 0; |
92 | 90 |
93 virtual scoped_ptr<syncable::DirectoryBackingStore> | 91 virtual scoped_ptr<syncable::DirectoryBackingStore> |
94 BuildDirectoryBackingStore( | 92 BuildDirectoryBackingStore( |
95 const std::string& dir_name, | 93 const std::string& dir_name, |
96 const base::FilePath& backing_filepath) = 0; | 94 const base::FilePath& backing_filepath) = 0; |
97 | 95 |
98 // Returns the Switches struct that this object is using as configuration, if | 96 // Returns the Switches struct that this object is using as configuration, if |
99 // the implementation is making use of one. | 97 // the implementation is making use of one. |
100 virtual Switches GetSwitches() const = 0; | 98 virtual Switches GetSwitches() const = 0; |
101 }; | 99 }; |
102 | 100 |
103 } // namespace syncer | 101 } // namespace syncer |
104 | 102 |
105 #endif // SYNC_INTERNAL_API_PUBLIC_INTERNAL_COMPONENTS_FACTORY_H_ | 103 #endif // SYNC_INTERNAL_API_PUBLIC_INTERNAL_COMPONENTS_FACTORY_H_ |
OLD | NEW |