| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 CHROME_BROWSER_EXTENSIONS_API_STORAGE_SETTINGS_BACKEND_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_STORAGE_SETTINGS_BACKEND_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_API_STORAGE_SETTINGS_BACKEND_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_STORAGE_SETTINGS_BACKEND_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 virtual syncer::SyncError ProcessSyncChanges( | 65 virtual syncer::SyncError ProcessSyncChanges( |
| 66 const tracked_objects::Location& from_here, | 66 const tracked_objects::Location& from_here, |
| 67 const syncer::SyncChangeList& change_list) OVERRIDE; | 67 const syncer::SyncChangeList& change_list) OVERRIDE; |
| 68 virtual void StopSyncing(syncer::ModelType type) OVERRIDE; | 68 virtual void StopSyncing(syncer::ModelType type) OVERRIDE; |
| 69 | 69 |
| 70 private: | 70 private: |
| 71 // Gets a weak reference to the storage area for a given extension, | 71 // Gets a weak reference to the storage area for a given extension, |
| 72 // initializing sync with some initial data if sync enabled. | 72 // initializing sync with some initial data if sync enabled. |
| 73 SyncableSettingsStorage* GetOrCreateStorageWithSyncData( | 73 SyncableSettingsStorage* GetOrCreateStorageWithSyncData( |
| 74 const std::string& extension_id, | 74 const std::string& extension_id, |
| 75 const DictionaryValue& sync_data) const; | 75 const base::DictionaryValue& sync_data) const; |
| 76 | 76 |
| 77 // Gets all extension IDs known to extension settings. This may not be all | 77 // Gets all extension IDs known to extension settings. This may not be all |
| 78 // installed extensions. | 78 // installed extensions. |
| 79 std::set<std::string> GetKnownExtensionIDs() const; | 79 std::set<std::string> GetKnownExtensionIDs() const; |
| 80 | 80 |
| 81 // Creates a new SettingsSyncProcessor for an extension. | 81 // Creates a new SettingsSyncProcessor for an extension. |
| 82 scoped_ptr<SettingsSyncProcessor> CreateSettingsSyncProcessor( | 82 scoped_ptr<SettingsSyncProcessor> CreateSettingsSyncProcessor( |
| 83 const std::string& extension_id) const; | 83 const std::string& extension_id) const; |
| 84 | 84 |
| 85 // The Factory to use for creating leveldb storage areas. | 85 // The Factory to use for creating leveldb storage areas. |
| (...skipping 24 matching lines...) Expand all Loading... |
| 110 scoped_ptr<syncer::SyncErrorFactory> sync_error_factory_; | 110 scoped_ptr<syncer::SyncErrorFactory> sync_error_factory_; |
| 111 | 111 |
| 112 syncer::SyncableService::StartSyncFlare flare_; | 112 syncer::SyncableService::StartSyncFlare flare_; |
| 113 | 113 |
| 114 DISALLOW_COPY_AND_ASSIGN(SettingsBackend); | 114 DISALLOW_COPY_AND_ASSIGN(SettingsBackend); |
| 115 }; | 115 }; |
| 116 | 116 |
| 117 } // namespace extensions | 117 } // namespace extensions |
| 118 | 118 |
| 119 #endif // CHROME_BROWSER_EXTENSIONS_API_STORAGE_SETTINGS_BACKEND_H_ | 119 #endif // CHROME_BROWSER_EXTENSIONS_API_STORAGE_SETTINGS_BACKEND_H_ |
| OLD | NEW |