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

Unified Diff: components/sync/api/entity_change.h

Issue 2222373003: [Sync] Adding storage key concept for ModelTypeServices. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removing redundant hash value. Created 4 years, 4 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 | « components/sync/api/data_batch.h ('k') | components/sync/api/entity_change.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/sync/api/entity_change.h
diff --git a/components/sync/api/entity_change.h b/components/sync/api/entity_change.h
index dd6195649697ea2140e208cfde36701fc69d784f..db7f3b748ce8f3a42c24058a1905886c42d0c4ea 100644
--- a/components/sync/api/entity_change.h
+++ b/components/sync/api/entity_change.h
@@ -17,21 +17,25 @@ class SYNC_EXPORT EntityChange {
public:
enum ChangeType { ACTION_ADD, ACTION_UPDATE, ACTION_DELETE };
- static EntityChange CreateAdd(std::string client_tag, EntityDataPtr data);
- static EntityChange CreateUpdate(std::string client_tag, EntityDataPtr data);
- static EntityChange CreateDelete(std::string client_tag);
+ static EntityChange CreateAdd(const std::string& storage_key,
+ EntityDataPtr data);
+ static EntityChange CreateUpdate(const std::string& storage_key,
+ EntityDataPtr data);
+ static EntityChange CreateDelete(const std::string& storage_key);
EntityChange(const EntityChange& other);
virtual ~EntityChange();
- std::string client_tag() const { return client_tag_; }
+ std::string storage_key() const { return storage_key_; }
ChangeType type() const { return type_; }
const EntityData& data() const { return data_.value(); }
private:
- EntityChange(std::string client_tag, ChangeType type, EntityDataPtr data);
+ EntityChange(const std::string& storage_key,
+ ChangeType type,
+ EntityDataPtr data);
- std::string client_tag_;
+ std::string storage_key_;
ChangeType type_;
EntityDataPtr data_;
};
« no previous file with comments | « components/sync/api/data_batch.h ('k') | components/sync/api/entity_change.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698