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

Side by Side Diff: chrome/browser/extensions/api/storage/sync_storage_backend.h

Issue 1141963002: Remove a bunch of DeepCopy() calls in the chrome.storage API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments Created 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_EXTENSIONS_API_STORAGE_SYNC_STORAGE_BACKEND_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_STORAGE_SYNC_STORAGE_BACKEND_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_STORAGE_SYNC_STORAGE_BACKEND_H_ 6 #define CHROME_BROWSER_EXTENSIONS_API_STORAGE_SYNC_STORAGE_BACKEND_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 syncer::SyncError ProcessSyncChanges( 60 syncer::SyncError ProcessSyncChanges(
61 const tracked_objects::Location& from_here, 61 const tracked_objects::Location& from_here,
62 const syncer::SyncChangeList& change_list) override; 62 const syncer::SyncChangeList& change_list) override;
63 void StopSyncing(syncer::ModelType type) override; 63 void StopSyncing(syncer::ModelType type) override;
64 64
65 private: 65 private:
66 // Gets a weak reference to the storage area for a given extension, 66 // Gets a weak reference to the storage area for a given extension,
67 // initializing sync with some initial data if sync enabled. 67 // initializing sync with some initial data if sync enabled.
68 SyncableSettingsStorage* GetOrCreateStorageWithSyncData( 68 SyncableSettingsStorage* GetOrCreateStorageWithSyncData(
69 const std::string& extension_id, 69 const std::string& extension_id,
70 const base::DictionaryValue& sync_data) const; 70 scoped_ptr<base::DictionaryValue> sync_data) const;
71 71
72 // Gets all extension IDs known to extension settings. This may not be all 72 // Gets all extension IDs known to extension settings. This may not be all
73 // installed extensions. 73 // installed extensions.
74 std::set<std::string> GetKnownExtensionIDs() const; 74 std::set<std::string> GetKnownExtensionIDs() const;
75 75
76 // Creates a new SettingsSyncProcessor for an extension. 76 // Creates a new SettingsSyncProcessor for an extension.
77 scoped_ptr<SettingsSyncProcessor> CreateSettingsSyncProcessor( 77 scoped_ptr<SettingsSyncProcessor> CreateSettingsSyncProcessor(
78 const std::string& extension_id) const; 78 const std::string& extension_id) const;
79 79
80 // The Factory to use for creating new ValueStores. 80 // The Factory to use for creating new ValueStores.
(...skipping 24 matching lines...) Expand all
105 scoped_ptr<syncer::SyncErrorFactory> sync_error_factory_; 105 scoped_ptr<syncer::SyncErrorFactory> sync_error_factory_;
106 106
107 syncer::SyncableService::StartSyncFlare flare_; 107 syncer::SyncableService::StartSyncFlare flare_;
108 108
109 DISALLOW_COPY_AND_ASSIGN(SyncStorageBackend); 109 DISALLOW_COPY_AND_ASSIGN(SyncStorageBackend);
110 }; 110 };
111 111
112 } // namespace extensions 112 } // namespace extensions
113 113
114 #endif // CHROME_BROWSER_EXTENSIONS_API_STORAGE_SYNC_STORAGE_BACKEND_H_ 114 #endif // CHROME_BROWSER_EXTENSIONS_API_STORAGE_SYNC_STORAGE_BACKEND_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698