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

Side by Side Diff: sync/syncable/mutable_entry.h

Issue 302173004: sync: Specialize functions that fetch type root (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: s/GET_BY_SERVER_TAG_DEPRECATED/GET_BY_SERVER_TAG/ Created 6 years, 6 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
« no previous file with comments | « sync/syncable/model_neutral_mutable_entry.cc ('k') | sync/syncable/mutable_entry.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 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_SYNCABLE_MUTABLE_ENTRY_H_ 5 #ifndef SYNC_SYNCABLE_MUTABLE_ENTRY_H_
6 #define SYNC_SYNCABLE_MUTABLE_ENTRY_H_ 6 #define SYNC_SYNCABLE_MUTABLE_ENTRY_H_
7 7
8 #include "sync/base/sync_export.h" 8 #include "sync/base/sync_export.h"
9 #include "sync/internal_api/public/base/model_type.h" 9 #include "sync/internal_api/public/base/model_type.h"
10 #include "sync/syncable/entry.h" 10 #include "sync/syncable/entry.h"
(...skipping 17 matching lines...) Expand all
28 void Init(WriteTransaction* trans, ModelType model_type, 28 void Init(WriteTransaction* trans, ModelType model_type,
29 const Id& parent_id, const std::string& name); 29 const Id& parent_id, const std::string& name);
30 30
31 public: 31 public:
32 MutableEntry(WriteTransaction* trans, CreateNewUpdateItem, const Id& id); 32 MutableEntry(WriteTransaction* trans, CreateNewUpdateItem, const Id& id);
33 MutableEntry(WriteTransaction* trans, Create, ModelType model_type, 33 MutableEntry(WriteTransaction* trans, Create, ModelType model_type,
34 const Id& parent_id, const std::string& name); 34 const Id& parent_id, const std::string& name);
35 MutableEntry(WriteTransaction* trans, GetByHandle, int64); 35 MutableEntry(WriteTransaction* trans, GetByHandle, int64);
36 MutableEntry(WriteTransaction* trans, GetById, const Id&); 36 MutableEntry(WriteTransaction* trans, GetById, const Id&);
37 MutableEntry(WriteTransaction* trans, GetByClientTag, const std::string& tag); 37 MutableEntry(WriteTransaction* trans, GetByClientTag, const std::string& tag);
38 MutableEntry(WriteTransaction* trans, GetByServerTag, const std::string& tag); 38 MutableEntry(WriteTransaction* trans, GetTypeRoot, ModelType type);
39 39
40 inline WriteTransaction* write_transaction() const { 40 inline WriteTransaction* write_transaction() const {
41 return write_transaction_; 41 return write_transaction_;
42 } 42 }
43 43
44 // Model-changing setters. These setters make user-visible changes that will 44 // Model-changing setters. These setters make user-visible changes that will
45 // need to be communicated either to the local model or the sync server. 45 // need to be communicated either to the local model or the sync server.
46 void PutLocalExternalId(int64 value); 46 void PutLocalExternalId(int64 value);
47 void PutMtime(base::Time value); 47 void PutMtime(base::Time value);
48 void PutCtime(base::Time value); 48 void PutCtime(base::Time value);
(...skipping 28 matching lines...) Expand all
77 DISALLOW_COPY_AND_ASSIGN(MutableEntry); 77 DISALLOW_COPY_AND_ASSIGN(MutableEntry);
78 }; 78 };
79 79
80 // This function sets only the flags needed to get this entry to sync. 80 // This function sets only the flags needed to get this entry to sync.
81 bool MarkForSyncing(syncable::MutableEntry* e); 81 bool MarkForSyncing(syncable::MutableEntry* e);
82 82
83 } // namespace syncable 83 } // namespace syncable
84 } // namespace syncer 84 } // namespace syncer
85 85
86 #endif // SYNC_SYNCABLE_MUTABLE_ENTRY_H_ 86 #endif // SYNC_SYNCABLE_MUTABLE_ENTRY_H_
OLDNEW
« no previous file with comments | « sync/syncable/model_neutral_mutable_entry.cc ('k') | sync/syncable/mutable_entry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698