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

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

Issue 165223003: Add a Restore() method to ValueStore and make StorageAPI use it (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Latest master Created 6 years, 10 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 (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_WEAK_UNLIMITED_SETTINGS_STORAGE_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_STORAGE_WEAK_UNLIMITED_SETTINGS_STORAGE_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_STORAGE_WEAK_UNLIMITED_SETTINGS_STORAGE_H_ 6 #define CHROME_BROWSER_EXTENSIONS_API_STORAGE_WEAK_UNLIMITED_SETTINGS_STORAGE_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "chrome/browser/value_store/value_store.h" 9 #include "chrome/browser/value_store/value_store.h"
10 10
(...skipping 18 matching lines...) Expand all
29 virtual ReadResult Get() OVERRIDE; 29 virtual ReadResult Get() OVERRIDE;
30 virtual WriteResult Set( 30 virtual WriteResult Set(
31 WriteOptions options, 31 WriteOptions options,
32 const std::string& key, 32 const std::string& key,
33 const base::Value& value) OVERRIDE; 33 const base::Value& value) OVERRIDE;
34 virtual WriteResult Set( 34 virtual WriteResult Set(
35 WriteOptions options, const base::DictionaryValue& values) OVERRIDE; 35 WriteOptions options, const base::DictionaryValue& values) OVERRIDE;
36 virtual WriteResult Remove(const std::string& key) OVERRIDE; 36 virtual WriteResult Remove(const std::string& key) OVERRIDE;
37 virtual WriteResult Remove(const std::vector<std::string>& keys) OVERRIDE; 37 virtual WriteResult Remove(const std::vector<std::string>& keys) OVERRIDE;
38 virtual WriteResult Clear() OVERRIDE; 38 virtual WriteResult Clear() OVERRIDE;
39 virtual bool Restore() OVERRIDE;
40 virtual bool RestoreKey(const std::string& key) OVERRIDE;
39 41
40 private: 42 private:
41 // The delegate storage area, NOT OWNED. 43 // The delegate storage area, NOT OWNED.
42 ValueStore* const delegate_; 44 ValueStore* const delegate_;
43 45
44 DISALLOW_COPY_AND_ASSIGN(WeakUnlimitedSettingsStorage); 46 DISALLOW_COPY_AND_ASSIGN(WeakUnlimitedSettingsStorage);
45 }; 47 };
46 48
47 } // namespace extensions 49 } // namespace extensions
48 50
49 #endif // CHROME_BROWSER_EXTENSIONS_API_STORAGE_WEAK_UNLIMITED_SETTINGS_STORAGE _H_ 51 #endif // CHROME_BROWSER_EXTENSIONS_API_STORAGE_WEAK_UNLIMITED_SETTINGS_STORAGE _H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698