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

Unified Diff: sync/syncable/entry.h

Issue 302173004: sync: Specialize functions that fetch type root (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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/syncable/directory.cc ('k') | sync/syncable/entry.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/syncable/entry.h
diff --git a/sync/syncable/entry.h b/sync/syncable/entry.h
index 47b9c593301d0d96f88aefef8f4f9f7d5d80a6b1..8ac2735fe46513ad71ab3004de87fd0f9513cf00 100644
--- a/sync/syncable/entry.h
+++ b/sync/syncable/entry.h
@@ -35,7 +35,12 @@ enum GetByClientTag {
};
enum GetByServerTag {
- GET_BY_SERVER_TAG
+ // Server tagged items are deprecated for all types but bookmarks.
+ GET_BY_SERVER_TAG_DEPRECATED
tim (not reviewing) 2014/06/03 15:21:22 The decision to deprecate this seems separate from
rlarocque 2014/06/03 17:29:40 I added a suffix because I wanted the compiler to
+};
+
+enum GetTypeRoot {
+ GET_TYPE_ROOT
};
enum GetByHandle {
@@ -48,9 +53,13 @@ class SYNC_EXPORT Entry {
// succeeded.
Entry(BaseTransaction* trans, GetByHandle, int64 handle);
Entry(BaseTransaction* trans, GetById, const Id& id);
- Entry(BaseTransaction* trans, GetByServerTag, const std::string& tag);
+ Entry(BaseTransaction* trans, GetTypeRoot, ModelType type);
Entry(BaseTransaction* trans, GetByClientTag, const std::string& tag);
+ // This lookup function is deprecated. All types except bookmarks can use
+ // the GetTypeRoot variant instead.
+ Entry(BaseTransaction* trans, GetByServerTag, const std::string& tag);
+
bool good() const { return 0 != kernel_; }
BaseTransaction* trans() const { return basetrans_; }
« no previous file with comments | « sync/syncable/directory.cc ('k') | sync/syncable/entry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698