OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ | 5 #ifndef CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ |
6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ | 6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 class RemoteChangeProcessor; | 47 class RemoteChangeProcessor; |
48 | 48 |
49 namespace drive_backend { | 49 namespace drive_backend { |
50 | 50 |
51 class DriveServiceWrapper; | 51 class DriveServiceWrapper; |
52 class DriveUploaderWrapper; | 52 class DriveUploaderWrapper; |
53 class MetadataDatabase; | 53 class MetadataDatabase; |
54 class RemoteChangeProcessorOnWorker; | 54 class RemoteChangeProcessorOnWorker; |
55 class RemoteChangeProcessorWrapper; | 55 class RemoteChangeProcessorWrapper; |
56 class SyncTaskManager; | 56 class SyncTaskManager; |
57 class SyncWorker; | 57 class SyncWorkerInterface; |
58 | 58 |
59 class SyncEngine : public RemoteFileSyncService, | 59 class SyncEngine : public RemoteFileSyncService, |
60 public LocalChangeProcessor, | 60 public LocalChangeProcessor, |
61 public drive::DriveNotificationObserver, | 61 public drive::DriveNotificationObserver, |
62 public drive::DriveServiceObserver, | 62 public drive::DriveServiceObserver, |
63 public net::NetworkChangeNotifier::NetworkChangeObserver { | 63 public net::NetworkChangeNotifier::NetworkChangeObserver { |
64 public: | 64 public: |
65 typedef Observer SyncServiceObserver; | 65 typedef Observer SyncServiceObserver; |
66 | 66 |
67 static scoped_ptr<SyncEngine> CreateForBrowserContext( | 67 static scoped_ptr<SyncEngine> CreateForBrowserContext( |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 RemoteChangeProcessor* remote_change_processor_; // Not owned. | 187 RemoteChangeProcessor* remote_change_processor_; // Not owned. |
188 scoped_ptr<RemoteChangeProcessorWrapper> remote_change_processor_wrapper_; | 188 scoped_ptr<RemoteChangeProcessorWrapper> remote_change_processor_wrapper_; |
189 // Delete this on worker. | 189 // Delete this on worker. |
190 scoped_ptr<RemoteChangeProcessorOnWorker> remote_change_processor_on_worker_; | 190 scoped_ptr<RemoteChangeProcessorOnWorker> remote_change_processor_on_worker_; |
191 | 191 |
192 RemoteServiceState service_state_; | 192 RemoteServiceState service_state_; |
193 bool sync_enabled_; | 193 bool sync_enabled_; |
194 | 194 |
195 // Delete them on worker. | 195 // Delete them on worker. |
196 scoped_ptr<WorkerObserver> worker_observer_; | 196 scoped_ptr<WorkerObserver> worker_observer_; |
197 scoped_ptr<SyncWorker> sync_worker_; | 197 scoped_ptr<SyncWorkerInterface> sync_worker_; |
198 | 198 |
199 ObserverList<SyncServiceObserver> service_observers_; | 199 ObserverList<SyncServiceObserver> service_observers_; |
200 ObserverList<FileStatusObserver> file_status_observers_; | 200 ObserverList<FileStatusObserver> file_status_observers_; |
201 leveldb::Env* env_override_; | 201 leveldb::Env* env_override_; |
202 | 202 |
203 CallbackTracker callback_tracker_; | 203 CallbackTracker callback_tracker_; |
204 | 204 |
205 base::WeakPtrFactory<SyncEngine> weak_ptr_factory_; | 205 base::WeakPtrFactory<SyncEngine> weak_ptr_factory_; |
206 DISALLOW_COPY_AND_ASSIGN(SyncEngine); | 206 DISALLOW_COPY_AND_ASSIGN(SyncEngine); |
207 }; | 207 }; |
208 | 208 |
209 } // namespace drive_backend | 209 } // namespace drive_backend |
210 } // namespace sync_file_system | 210 } // namespace sync_file_system |
211 | 211 |
212 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ | 212 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ |
OLD | NEW |