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

Unified Diff: chrome/browser/chromeos/cros_settings_provider.h

Issue 8091002: PART2: Make SignedSettings use proper Value types instead of string all around the place. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments and rebased on a the current PART1 version. Created 9 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/cros_settings_provider.h
diff --git a/chrome/browser/chromeos/cros_settings_provider.h b/chrome/browser/chromeos/cros_settings_provider.h
index e5012c346ca567b9eb761c77961a8e9446058a2a..fca9520e7317315a7e95d8775d5c54679a54d514 100644
--- a/chrome/browser/chromeos/cros_settings_provider.h
+++ b/chrome/browser/chromeos/cros_settings_provider.h
@@ -20,14 +20,15 @@ class CrosSettingsProvider {
virtual ~CrosSettingsProvider() {}
// Sets |in_value| to given |path| in cros settings.
- // Note that this takes ownership of |in_value|.
- void Set(const std::string& path, base::Value* in_value);
+ void Set(const std::string& path, const base::Value& in_value);
// Gets settings value of given |path| to |out_value|.
virtual const base::Value* Get(const std::string& path) const = 0;
- // Starts a fetch from the trusted store for the value of |path|. It will
- // call the |callback| function upon completion.
+ // Starts a fetch from the trusted store for the value of |path| if not loaded
+ // yet. It will call the |callback| function upon completion if a new fetch
+ // was needed in which case the return value is false. Else it will return
+ // true and win't call the |callback|.
Denis Lagno 2011/10/13 13:43:10 won't
pastarmovj 2011/10/26 15:44:59 Done.
virtual bool GetTrusted(const std::string& path,
const base::Closure& callback) const = 0;
@@ -36,7 +37,8 @@ class CrosSettingsProvider {
private:
// Does the real job for Set().
- virtual void DoSet(const std::string& path, base::Value* in_value) = 0;
+ virtual void DoSet(const std::string& path,
+ const base::Value& in_value) = 0;
};
} // namespace chromeos

Powered by Google App Engine
This is Rietveld 408576698