| 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 #ifndef COMPONENTS_SYNC_CORE_SYNC_MANAGER_H_ | 5 #ifndef COMPONENTS_SYNC_CORE_SYNC_MANAGER_H_ |
| 6 #define COMPONENTS_SYNC_CORE_SYNC_MANAGER_H_ | 6 #define COMPONENTS_SYNC_CORE_SYNC_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 359 // Note: opens a transaction. May be called on any thread. | 359 // Note: opens a transaction. May be called on any thread. |
| 360 virtual bool ReceivedExperiment(Experiments* experiments) = 0; | 360 virtual bool ReceivedExperiment(Experiments* experiments) = 0; |
| 361 | 361 |
| 362 // Uses a read-only transaction to determine if the directory being synced has | 362 // Uses a read-only transaction to determine if the directory being synced has |
| 363 // any remaining unsynced items. May be called on any thread. | 363 // any remaining unsynced items. May be called on any thread. |
| 364 virtual bool HasUnsyncedItems() = 0; | 364 virtual bool HasUnsyncedItems() = 0; |
| 365 | 365 |
| 366 // Returns the SyncManager's encryption handler. | 366 // Returns the SyncManager's encryption handler. |
| 367 virtual SyncEncryptionHandler* GetEncryptionHandler() = 0; | 367 virtual SyncEncryptionHandler* GetEncryptionHandler() = 0; |
| 368 | 368 |
| 369 virtual std::unique_ptr<base::ListValue> GetAllNodesForType( | |
| 370 syncer::ModelType type) = 0; | |
| 371 | |
| 372 // Ask the SyncManager to fetch updates for the given types. | 369 // Ask the SyncManager to fetch updates for the given types. |
| 373 virtual void RefreshTypes(ModelTypeSet types) = 0; | 370 virtual void RefreshTypes(ModelTypeSet types) = 0; |
| 374 | 371 |
| 375 // Returns any buffered protocol events. Does not clear the buffer. | 372 // Returns any buffered protocol events. Does not clear the buffer. |
| 376 virtual std::vector<std::unique_ptr<ProtocolEvent>> | 373 virtual std::vector<std::unique_ptr<ProtocolEvent>> |
| 377 GetBufferedProtocolEvents() = 0; | 374 GetBufferedProtocolEvents() = 0; |
| 378 | 375 |
| 379 // Functions to manage registrations of DebugInfoObservers. | 376 // Functions to manage registrations of DebugInfoObservers. |
| 380 virtual void RegisterDirectoryTypeDebugInfoObserver( | 377 virtual void RegisterDirectoryTypeDebugInfoObserver( |
| 381 syncer::TypeDebugInfoObserver* observer) = 0; | 378 syncer::TypeDebugInfoObserver* observer) = 0; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 397 | 394 |
| 398 // Updates Sync's tracking of whether the cookie jar has a mismatch with the | 395 // Updates Sync's tracking of whether the cookie jar has a mismatch with the |
| 399 // chrome account. See ClientConfigParams proto message for more info. | 396 // chrome account. See ClientConfigParams proto message for more info. |
| 400 // Note: this does not trigger a sync cycle. It just updates the sync context. | 397 // Note: this does not trigger a sync cycle. It just updates the sync context. |
| 401 virtual void OnCookieJarChanged(bool account_mismatch, bool empty_jar) = 0; | 398 virtual void OnCookieJarChanged(bool account_mismatch, bool empty_jar) = 0; |
| 402 }; | 399 }; |
| 403 | 400 |
| 404 } // namespace syncer | 401 } // namespace syncer |
| 405 | 402 |
| 406 #endif // COMPONENTS_SYNC_CORE_SYNC_MANAGER_H_ | 403 #endif // COMPONENTS_SYNC_CORE_SYNC_MANAGER_H_ |
| OLD | NEW |