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

Side by Side Diff: sync/internal_api/public/engine/model_safe_worker.h

Issue 1848793006: [Sync] Register USS types with ModelTypeRegistry before download (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments from Sky and Max. Created 4 years, 8 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
OLDNEW
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 SYNC_INTERNAL_API_PUBLIC_ENGINE_MODEL_SAFE_WORKER_H_ 5 #ifndef SYNC_INTERNAL_API_PUBLIC_ENGINE_MODEL_SAFE_WORKER_H_
6 #define SYNC_INTERNAL_API_PUBLIC_ENGINE_MODEL_SAFE_WORKER_H_ 6 #define SYNC_INTERNAL_API_PUBLIC_ENGINE_MODEL_SAFE_WORKER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 24 matching lines...) Expand all
35 // changes to these models don't need to be pushed to a 35 // changes to these models don't need to be pushed to a
36 // native model. 36 // native model.
37 GROUP_UI, // Models that live on UI thread and are being synced. 37 GROUP_UI, // Models that live on UI thread and are being synced.
38 GROUP_DB, // Models that live on DB thread and are being synced. 38 GROUP_DB, // Models that live on DB thread and are being synced.
39 GROUP_FILE, // Models that live on FILE thread and are being synced. 39 GROUP_FILE, // Models that live on FILE thread and are being synced.
40 GROUP_HISTORY, // Models that live on history thread and are being 40 GROUP_HISTORY, // Models that live on history thread and are being
41 // synced. 41 // synced.
42 GROUP_PASSWORD, // Models that live on the password thread and are 42 GROUP_PASSWORD, // Models that live on the password thread and are
43 // being synced. On windows and linux, this runs on the 43 // being synced. On windows and linux, this runs on the
44 // DB thread. 44 // DB thread.
45 MODEL_SAFE_GROUP_COUNT, 45 GROUP_NON_BLOCKING, // Models that correspond to non-blocking types. These
46 // models always stay in GROUP_NON_BLOCKING, changest are
maxbogue 2016/04/04 18:08:14 s/, changest/; changes/
pavely 2016/04/05 18:21:52 Done. Thanks.
47 // forwarded to these models without ModelSafeWorker/
48 // SyncBackendRegistrar involvement.
46 }; 49 };
47 50
48 SYNC_EXPORT std::string ModelSafeGroupToString(ModelSafeGroup group); 51 SYNC_EXPORT std::string ModelSafeGroupToString(ModelSafeGroup group);
49 52
50 // WorkerLoopDestructionObserver is notified when the thread where it works 53 // WorkerLoopDestructionObserver is notified when the thread where it works
51 // is going to be destroyed. 54 // is going to be destroyed.
52 class WorkerLoopDestructionObserver { 55 class WorkerLoopDestructionObserver {
53 public: 56 public:
54 virtual void OnWorkerLoopDestroyed(ModelSafeGroup group) = 0; 57 virtual void OnWorkerLoopDestroyed(ModelSafeGroup group) = 0;
55 }; 58 };
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 SYNC_EXPORT ModelTypeSet GetRoutingInfoTypes( 161 SYNC_EXPORT ModelTypeSet GetRoutingInfoTypes(
159 const ModelSafeRoutingInfo& routing_info); 162 const ModelSafeRoutingInfo& routing_info);
160 163
161 SYNC_EXPORT ModelSafeGroup GetGroupForModelType( 164 SYNC_EXPORT ModelSafeGroup GetGroupForModelType(
162 const ModelType type, 165 const ModelType type,
163 const ModelSafeRoutingInfo& routes); 166 const ModelSafeRoutingInfo& routes);
164 167
165 } // namespace syncer 168 } // namespace syncer
166 169
167 #endif // SYNC_INTERNAL_API_PUBLIC_ENGINE_MODEL_SAFE_WORKER_H_ 170 #endif // SYNC_INTERNAL_API_PUBLIC_ENGINE_MODEL_SAFE_WORKER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698