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

Side by Side Diff: chrome/browser/extensions/settings/failing_settings_storage.h

Issue 8587025: Extension settings API: force through changes that come from sync (ignoring (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_SETTINGS_FAILING_SETTINGS_STORAGE_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_SETTINGS_FAILING_SETTINGS_STORAGE_H_
6 #define CHROME_BROWSER_EXTENSIONS_SETTINGS_FAILING_SETTINGS_STORAGE_H_ 6 #define CHROME_BROWSER_EXTENSIONS_SETTINGS_FAILING_SETTINGS_STORAGE_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "chrome/browser/extensions/settings/settings_storage.h" 10 #include "chrome/browser/extensions/settings/settings_storage.h"
11 11
12 namespace extensions { 12 namespace extensions {
13 13
14 // Settings storage area which fails every request. 14 // Settings storage area which fails every request.
15 class FailingSettingsStorage : public SettingsStorage { 15 class FailingSettingsStorage : public SettingsStorage {
16 public: 16 public:
17 FailingSettingsStorage() {} 17 FailingSettingsStorage() {}
18 18
19 // SettingsStorage implementation. 19 // SettingsStorage implementation.
20 virtual ReadResult Get(const std::string& key) OVERRIDE; 20 virtual ReadResult Get(const std::string& key) OVERRIDE;
21 virtual ReadResult Get(const std::vector<std::string>& keys) OVERRIDE; 21 virtual ReadResult Get(const std::vector<std::string>& keys) OVERRIDE;
22 virtual ReadResult Get() OVERRIDE; 22 virtual ReadResult Get() OVERRIDE;
23 virtual WriteResult Set(const std::string& key, const Value& value) OVERRIDE; 23 virtual WriteResult Set(
24 virtual WriteResult Set(const DictionaryValue& values) OVERRIDE; 24 WriteOptions options,
25 virtual WriteResult Remove(const std::string& key) OVERRIDE; 25 const std::string& key,
26 virtual WriteResult Remove(const std::vector<std::string>& keys) OVERRIDE; 26 const Value& value) OVERRIDE;
27 virtual WriteResult Clear() OVERRIDE; 27 virtual WriteResult Set(
28 WriteOptions options, const DictionaryValue& values) OVERRIDE;
29 virtual WriteResult Remove(
30 WriteOptions options, const std::string& key) OVERRIDE;
31 virtual WriteResult Remove(
32 WriteOptions options, const std::vector<std::string>& keys) OVERRIDE;
33 virtual WriteResult Clear(WriteOptions options) OVERRIDE;
28 34
29 private: 35 private:
30 DISALLOW_COPY_AND_ASSIGN(FailingSettingsStorage); 36 DISALLOW_COPY_AND_ASSIGN(FailingSettingsStorage);
31 }; 37 };
32 38
33 } // namespace extensions 39 } // namespace extensions
34 40
35 #endif // CHROME_BROWSER_EXTENSIONS_SETTINGS_FAILING_SETTINGS_STORAGE_H_ 41 #endif // CHROME_BROWSER_EXTENSIONS_SETTINGS_FAILING_SETTINGS_STORAGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698