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

Unified Diff: components/drive/chromeos/change_list_processor.h

Issue 2799603002: Process TeamDrive change in change list. (Closed)
Patch Set: Add test for update. Created 3 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 side-by-side diff with in-line comments
Download patch
Index: components/drive/chromeos/change_list_processor.h
diff --git a/components/drive/chromeos/change_list_processor.h b/components/drive/chromeos/change_list_processor.h
index 0c23efa0d41a973e3df8468aaea60459dbfeeeae..ee06c199fcff079d1b6299ee0827a3a2f6d75eec 100644
--- a/components/drive/chromeos/change_list_processor.h
+++ b/components/drive/chromeos/change_list_processor.h
@@ -33,6 +33,7 @@ namespace drive {
class FileChange;
class ResourceEntry;
+class TeamDriveChange;
namespace internal {
@@ -82,6 +83,10 @@ class ChangeList {
const std::vector<ResourceEntry>& entries() const { return entries_; }
std::vector<ResourceEntry>* mutable_entries() { return &entries_; }
+ const std::vector<TeamDriveChange>& team_drives() const {
+ return team_drives_;
+ }
+ std::vector<TeamDriveChange>* mutable_team_drives() { return &team_drives_; }
const std::vector<std::string>& parent_resource_ids() const {
return parent_resource_ids_;
}
@@ -97,6 +102,7 @@ class ChangeList {
private:
std::vector<ResourceEntry> entries_;
+ std::vector<TeamDriveChange> team_drives_;
std::vector<std::string> parent_resource_ids_;
GURL next_url_;
int64_t largest_changestamp_;
@@ -154,6 +160,9 @@ class ChangeListProcessor {
// Apply |entry| to resource_metadata_.
FileError ApplyEntry(const ResourceEntry& entry);
+ // Converts |change| to a ResourceEntry and apply to resource_metadata_.
+ FileError ApplyTeamDriveChange(const TeamDriveChange& change);
+
// Adds the directories changed by the update on |entry| to |changed_dirs_|.
void UpdateChangedDirs(const ResourceEntry& entry);

Powered by Google App Engine
This is Rietveld 408576698