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

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

Issue 8491033: Extension Settings API: throttle the API in the same way that the Bookmarks API (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync, use SingletonBucketMapper 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_SETTINGS_API_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_SETTINGS_SETTINGS_API_H_
6 #define CHROME_BROWSER_EXTENSIONS_SETTINGS_SETTINGS_API_H_ 6 #define CHROME_BROWSER_EXTENSIONS_SETTINGS_SETTINGS_API_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 }; 59 };
60 60
61 class SetSettingsFunction : public SettingsFunction { 61 class SetSettingsFunction : public SettingsFunction {
62 public: 62 public:
63 DECLARE_EXTENSION_FUNCTION_NAME("experimental.settings.set"); 63 DECLARE_EXTENSION_FUNCTION_NAME("experimental.settings.set");
64 64
65 protected: 65 protected:
66 virtual bool RunWithStorage( 66 virtual bool RunWithStorage(
67 scoped_refptr<SettingsObserverList> observers, 67 scoped_refptr<SettingsObserverList> observers,
68 SettingsStorage* storage) OVERRIDE; 68 SettingsStorage* storage) OVERRIDE;
69
70 virtual void GetQuotaLimitHeuristics(
71 QuotaLimitHeuristics* heuristics) const OVERRIDE;
69 }; 72 };
70 73
71 class RemoveSettingsFunction : public SettingsFunction { 74 class RemoveSettingsFunction : public SettingsFunction {
72 public: 75 public:
73 DECLARE_EXTENSION_FUNCTION_NAME("experimental.settings.remove"); 76 DECLARE_EXTENSION_FUNCTION_NAME("experimental.settings.remove");
74 77
75 protected: 78 protected:
76 virtual bool RunWithStorage( 79 virtual bool RunWithStorage(
77 scoped_refptr<SettingsObserverList> observers, 80 scoped_refptr<SettingsObserverList> observers,
78 SettingsStorage* storage) OVERRIDE; 81 SettingsStorage* storage) OVERRIDE;
82
83 virtual void GetQuotaLimitHeuristics(
84 QuotaLimitHeuristics* heuristics) const OVERRIDE;
79 }; 85 };
80 86
81 class ClearSettingsFunction : public SettingsFunction { 87 class ClearSettingsFunction : public SettingsFunction {
82 public: 88 public:
83 DECLARE_EXTENSION_FUNCTION_NAME("experimental.settings.clear"); 89 DECLARE_EXTENSION_FUNCTION_NAME("experimental.settings.clear");
84 90
85 protected: 91 protected:
86 virtual bool RunWithStorage( 92 virtual bool RunWithStorage(
87 scoped_refptr<SettingsObserverList> observers, 93 scoped_refptr<SettingsObserverList> observers,
88 SettingsStorage* storage) OVERRIDE; 94 SettingsStorage* storage) OVERRIDE;
95
96 virtual void GetQuotaLimitHeuristics(
97 QuotaLimitHeuristics* heuristics) const OVERRIDE;
89 }; 98 };
90 99
91 } // namespace extensions 100 } // namespace extensions
92 101
93 #endif // CHROME_BROWSER_EXTENSIONS_SETTINGS_SETTINGS_API_H_ 102 #endif // CHROME_BROWSER_EXTENSIONS_SETTINGS_SETTINGS_API_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698