Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Side by Side Diff: sync/internal_api/public/sync_manager.h

Issue 10824161: [Sync] Avoid unregistering object IDs on shutdown (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Work around brittle unit test Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ 5 #ifndef SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_
6 #define SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ 6 #define SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 // Returns false if an error occurred, true otherwise. 400 // Returns false if an error occurred, true otherwise.
401 virtual bool PurgePartiallySyncedTypes() = 0; 401 virtual bool PurgePartiallySyncedTypes() = 0;
402 402
403 // Update tokens that we're using in Sync. Email must stay the same. 403 // Update tokens that we're using in Sync. Email must stay the same.
404 virtual void UpdateCredentials(const SyncCredentials& credentials) = 0; 404 virtual void UpdateCredentials(const SyncCredentials& credentials) = 0;
405 405
406 // Called when the user disables or enables a sync type. 406 // Called when the user disables or enables a sync type.
407 virtual void UpdateEnabledTypes( 407 virtual void UpdateEnabledTypes(
408 const ModelTypeSet& enabled_types) = 0; 408 const ModelTypeSet& enabled_types) = 0;
409 409
410 // Forwards to the underlying notifier (see 410 // Forwards to the underlying notifier (see comments in sync_notifier.h).
411 // SyncNotifier::UpdateRegisteredIds()). 411 virtual void RegisterInvalidationHandler(
412 SyncNotifierObserver* handler) = 0;
413
414 // Forwards to the underlying notifier (see comments in sync_notifier.h).
412 virtual void UpdateRegisteredInvalidationIds( 415 virtual void UpdateRegisteredInvalidationIds(
413 SyncNotifierObserver* handler, 416 SyncNotifierObserver* handler,
414 const ObjectIdSet& ids) = 0; 417 const ObjectIdSet& ids) = 0;
415 418
419 // Forwards to the underlying notifier (see comments in sync_notifier.h).
420 virtual void UnregisterInvalidationHandler(
421 SyncNotifierObserver* handler) = 0;
422
416 // Put the syncer in normal mode ready to perform nudges and polls. 423 // Put the syncer in normal mode ready to perform nudges and polls.
417 virtual void StartSyncingNormally( 424 virtual void StartSyncingNormally(
418 const ModelSafeRoutingInfo& routing_info) = 0; 425 const ModelSafeRoutingInfo& routing_info) = 0;
419 426
420 // Attempts to re-encrypt encrypted data types using the passphrase provided. 427 // Attempts to re-encrypt encrypted data types using the passphrase provided.
421 // Notifies observers of the result of the operation via OnPassphraseAccepted 428 // Notifies observers of the result of the operation via OnPassphraseAccepted
422 // or OnPassphraseRequired, updates the nigori node, and does re-encryption as 429 // or OnPassphraseRequired, updates the nigori node, and does re-encryption as
423 // appropriate. If an explicit password has been set previously, we drop 430 // appropriate. If an explicit password has been set previously, we drop
424 // subsequent requests to set a passphrase. If the cryptographer has pending 431 // subsequent requests to set a passphrase. If the cryptographer has pending
425 // keys, and a new implicit passphrase is provided, we try decrypting the 432 // keys, and a new implicit passphrase is provided, we try decrypting the
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
522 virtual bool ReceivedExperiment(Experiments* experiments) = 0; 529 virtual bool ReceivedExperiment(Experiments* experiments) = 0;
523 530
524 // Uses a read-only transaction to determine if the directory being synced has 531 // Uses a read-only transaction to determine if the directory being synced has
525 // any remaining unsynced items. May be called on any thread. 532 // any remaining unsynced items. May be called on any thread.
526 virtual bool HasUnsyncedItems() = 0; 533 virtual bool HasUnsyncedItems() = 0;
527 }; 534 };
528 535
529 } // namespace syncer 536 } // namespace syncer
530 537
531 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ 538 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/profile_sync_service_unittest.cc ('k') | sync/internal_api/public/test/fake_sync_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698