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

Unified Diff: sync/internal_api/sync_core.h

Issue 272323002: sync: Implement disabling of non blocking types (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review fixes Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sync/internal_api/public/test/null_sync_core_proxy.h ('k') | sync/internal_api/sync_core.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/internal_api/sync_core.h
diff --git a/sync/internal_api/sync_core.h b/sync/internal_api/sync_core.h
index 504304c8af61e4afde72194774da037d54a518fd..6f63070c01a6753f156852d446cb436e9e4b37f5 100644
--- a/sync/internal_api/sync_core.h
+++ b/sync/internal_api/sync_core.h
@@ -36,6 +36,17 @@ class SYNC_EXPORT_PRIVATE SyncCore {
scoped_refptr<base::SequencedTaskRunner> datatype_task_runner,
base::WeakPtr<NonBlockingTypeProcessor> sync_client);
+ // Disconnects the syncer from the model and stops syncing the type.
+ //
+ // By the time this is called, the model thread should have already
+ // invalidated the WeakPtr it sent to us in the connect request. Any
+ // messages sent to that NonBlockingTypeProcessor will not be recived.
+ //
+ // This is the sync thread's chance to clear state associated with the type.
+ // It also causes the syncer to stop requesting updates for this type, and to
+ // abort any in-progress commit requests.
+ void Disconnect(ModelType type);
+
base::WeakPtr<SyncCore> AsWeakPtr();
private:
« no previous file with comments | « sync/internal_api/public/test/null_sync_core_proxy.h ('k') | sync/internal_api/sync_core.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698