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

Side by Side Diff: sync/sessions/model_type_registry.h

Issue 1368683003: USS SyncContextProxy / data type activation refactoring (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed CR feedback Created 5 years, 2 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
« no previous file with comments | « sync/internal_api/test/null_sync_context_proxy.cc ('k') | sync/sessions/model_type_registry.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_ENGINE_MODEL_TYPE_REGISTRY_H_ 5 #ifndef SYNC_ENGINE_MODEL_TYPE_REGISTRY_H_
6 #define SYNC_ENGINE_MODEL_TYPE_REGISTRY_H_ 6 #define SYNC_ENGINE_MODEL_TYPE_REGISTRY_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 56
57 // Sets the set of enabled types. 57 // Sets the set of enabled types.
58 void SetEnabledDirectoryTypes(const ModelSafeRoutingInfo& routing_info); 58 void SetEnabledDirectoryTypes(const ModelSafeRoutingInfo& routing_info);
59 59
60 // Enables an off-thread type for syncing. Connects the given proxy 60 // Enables an off-thread type for syncing. Connects the given proxy
61 // and its task_runner to the newly created worker. 61 // and its task_runner to the newly created worker.
62 // 62 //
63 // Expects that the proxy's ModelType is not currently enabled. 63 // Expects that the proxy's ModelType is not currently enabled.
64 void ConnectSyncTypeToWorker( 64 void ConnectSyncTypeToWorker(
65 syncer::ModelType type, 65 syncer::ModelType type,
66 const syncer_v2::DataTypeState& data_type_state, 66 scoped_ptr<syncer_v2::ActivationContext> activation_context) override;
67 const syncer_v2::UpdateResponseDataList& saved_pending_updates,
68 const scoped_refptr<base::SequencedTaskRunner>& type_task_runner,
69 const base::WeakPtr<syncer_v2::ModelTypeProcessor>& type_processor)
70 override;
71 67
72 // Disables the syncing of an off-thread type. 68 // Disables the syncing of an off-thread type.
73 // 69 //
74 // Expects that the type is currently enabled. 70 // Expects that the type is currently enabled.
75 // Deletes the worker associated with the type. 71 // Deletes the worker associated with the type.
76 void DisconnectSyncWorker(syncer::ModelType type) override; 72 void DisconnectSyncWorker(syncer::ModelType type) override;
77 73
78 // Implementation of SyncEncryptionHandler::Observer. 74 // Implementation of SyncEncryptionHandler::Observer.
79 void OnPassphraseRequired( 75 void OnPassphraseRequired(
80 PassphraseRequiredReason reason, 76 PassphraseRequiredReason reason,
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 base::ObserverList<TypeDebugInfoObserver> type_debug_info_observers_; 156 base::ObserverList<TypeDebugInfoObserver> type_debug_info_observers_;
161 157
162 base::WeakPtrFactory<ModelTypeRegistry> weak_ptr_factory_; 158 base::WeakPtrFactory<ModelTypeRegistry> weak_ptr_factory_;
163 159
164 DISALLOW_COPY_AND_ASSIGN(ModelTypeRegistry); 160 DISALLOW_COPY_AND_ASSIGN(ModelTypeRegistry);
165 }; 161 };
166 162
167 } // namespace syncer 163 } // namespace syncer
168 164
169 #endif // SYNC_ENGINE_MODEL_TYPE_REGISTRY_H_ 165 #endif // SYNC_ENGINE_MODEL_TYPE_REGISTRY_H_
OLDNEW
« no previous file with comments | « sync/internal_api/test/null_sync_context_proxy.cc ('k') | sync/sessions/model_type_registry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698