Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_SYNC_DRIVER_SYNC_SERVICE_H_ | 5 #ifndef COMPONENTS_SYNC_DRIVER_SYNC_SERVICE_H_ |
| 6 #define COMPONENTS_SYNC_DRIVER_SYNC_SERVICE_H_ | 6 #define COMPONENTS_SYNC_DRIVER_SYNC_SERVICE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 96 virtual bool IsSyncAllowed() const = 0; | 96 virtual bool IsSyncAllowed() const = 0; |
| 97 | 97 |
| 98 // Returns true if sync is fully initialized and active. This implies that | 98 // Returns true if sync is fully initialized and active. This implies that |
| 99 // an initial configuration has successfully completed, although there may | 99 // an initial configuration has successfully completed, although there may |
| 100 // be datatype specific, auth, or other transient errors. To see which | 100 // be datatype specific, auth, or other transient errors. To see which |
| 101 // datetypes are actually syncing, see GetActiveTypes() below. | 101 // datetypes are actually syncing, see GetActiveTypes() below. |
| 102 // Note that if sync is in backup or rollback mode, IsSyncActive() will be | 102 // Note that if sync is in backup or rollback mode, IsSyncActive() will be |
| 103 // false. | 103 // false. |
| 104 virtual bool IsSyncActive() const = 0; | 104 virtual bool IsSyncActive() const = 0; |
| 105 | 105 |
| 106 // Triggers refresh of sync state. | |
|
Nicolas Zea
2015/10/23 20:20:10
nit: prefer being more specific about what this do
blundell
2015/10/26 07:59:36
Done.
| |
| 107 virtual void TriggerRefresh(const syncer::ModelTypeSet& types) = 0; | |
| 108 | |
| 106 // Get the set of current active data types (those chosen or configured by | 109 // Get the set of current active data types (those chosen or configured by |
| 107 // the user which have not also encountered a runtime error). | 110 // the user which have not also encountered a runtime error). |
| 108 // Note that if the Sync engine is in the middle of a configuration, this | 111 // Note that if the Sync engine is in the middle of a configuration, this |
| 109 // will the the empty set. Once the configuration completes the set will | 112 // will the the empty set. Once the configuration completes the set will |
| 110 // be updated. | 113 // be updated. |
| 111 virtual syncer::ModelTypeSet GetActiveDataTypes() const = 0; | 114 virtual syncer::ModelTypeSet GetActiveDataTypes() const = 0; |
| 112 | 115 |
| 113 // Returns the SyncClient instance associated with this service. | 116 // Returns the SyncClient instance associated with this service. |
| 114 virtual SyncClient* GetSyncClient() const = 0; | 117 virtual SyncClient* GetSyncClient() const = 0; |
| 115 | 118 |
| (...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 323 protected: | 326 protected: |
| 324 SyncService() {} | 327 SyncService() {} |
| 325 | 328 |
| 326 private: | 329 private: |
| 327 DISALLOW_COPY_AND_ASSIGN(SyncService); | 330 DISALLOW_COPY_AND_ASSIGN(SyncService); |
| 328 }; | 331 }; |
| 329 | 332 |
| 330 } // namespace sync_driver | 333 } // namespace sync_driver |
| 331 | 334 |
| 332 #endif // COMPONENTS_SYNC_DRIVER_SYNC_SERVICE_H_ | 335 #endif // COMPONENTS_SYNC_DRIVER_SYNC_SERVICE_H_ |
| OLD | NEW |