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

Side by Side Diff: chrome/browser/chromeos/printing/printers_sync_bridge.h

Issue 2923363004: [Sync] Migrate bridge implementations to change list based MergeSyncData (Closed)
Patch Set: Created 3 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/printing/printers_sync_bridge.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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 CHROME_BROWSER_CHROMEOS_PRINTING_PRINTERS_SYNC_BRIDGE_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_PRINTING_PRINTERS_SYNC_BRIDGE_H_
6 #define CHROME_BROWSER_CHROMEOS_PRINTING_PRINTERS_SYNC_BRIDGE_H_ 6 #define CHROME_BROWSER_CHROMEOS_PRINTING_PRINTERS_SYNC_BRIDGE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
(...skipping 17 matching lines...) Expand all
28 public: 28 public:
29 PrintersSyncBridge(const syncer::ModelTypeStoreFactory& callback, 29 PrintersSyncBridge(const syncer::ModelTypeStoreFactory& callback,
30 const base::RepeatingClosure& error_callback); 30 const base::RepeatingClosure& error_callback);
31 ~PrintersSyncBridge() override; 31 ~PrintersSyncBridge() override;
32 32
33 // ModelTypeSyncBridge implementation. 33 // ModelTypeSyncBridge implementation.
34 std::unique_ptr<syncer::MetadataChangeList> CreateMetadataChangeList() 34 std::unique_ptr<syncer::MetadataChangeList> CreateMetadataChangeList()
35 override; 35 override;
36 base::Optional<syncer::ModelError> MergeSyncData( 36 base::Optional<syncer::ModelError> MergeSyncData(
37 std::unique_ptr<syncer::MetadataChangeList> metadata_change_list, 37 std::unique_ptr<syncer::MetadataChangeList> metadata_change_list,
38 syncer::EntityDataMap entity_data_map) override; 38 syncer::EntityChangeList entity_data) override;
39 base::Optional<syncer::ModelError> ApplySyncChanges( 39 base::Optional<syncer::ModelError> ApplySyncChanges(
40 std::unique_ptr<syncer::MetadataChangeList> metadata_change_list, 40 std::unique_ptr<syncer::MetadataChangeList> metadata_change_list,
41 syncer::EntityChangeList entity_changes) override; 41 syncer::EntityChangeList entity_changes) override;
42 void GetData(StorageKeyList storage_keys, DataCallback callback) override; 42 void GetData(StorageKeyList storage_keys, DataCallback callback) override;
43 void GetAllData(DataCallback callback) override; 43 void GetAllData(DataCallback callback) override;
44 std::string GetClientTag(const syncer::EntityData& entity_data) override; 44 std::string GetClientTag(const syncer::EntityData& entity_data) override;
45 std::string GetStorageKey(const syncer::EntityData& entity_data) override; 45 std::string GetStorageKey(const syncer::EntityData& entity_data) override;
46 syncer::ConflictResolution ResolveConflict( 46 syncer::ConflictResolution ResolveConflict(
47 const syncer::EntityData& local_data, 47 const syncer::EntityData& local_data,
48 const syncer::EntityData& remote_data) const override; 48 const syncer::EntityData& remote_data) const override;
(...skipping 15 matching lines...) Expand all
64 64
65 // In memory cache of printer information. 65 // In memory cache of printer information.
66 std::map<std::string, std::unique_ptr<sync_pb::PrinterSpecifics>> all_data_; 66 std::map<std::string, std::unique_ptr<sync_pb::PrinterSpecifics>> all_data_;
67 67
68 DISALLOW_COPY_AND_ASSIGN(PrintersSyncBridge); 68 DISALLOW_COPY_AND_ASSIGN(PrintersSyncBridge);
69 }; 69 };
70 70
71 } // namespace chromeos 71 } // namespace chromeos
72 72
73 #endif // CHROME_BROWSER_CHROMEOS_PRINTING_PRINTERS_SYNC_BRIDGE_H_ 73 #endif // CHROME_BROWSER_CHROMEOS_PRINTING_PRINTERS_SYNC_BRIDGE_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/printing/printers_sync_bridge.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698