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

Unified Diff: base/win/registry.h

Issue 8344004: base/win: Add documentation to RegKey::Read/Write functions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add corner case comment 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
« no previous file with comments | « no previous file | base/win/registry.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/win/registry.h
diff --git a/base/win/registry.h b/base/win/registry.h
index 33052ff6bb0419d40a6c52022a445ebb87dde3bd..9bc15760e81dc4d6bf630f9c5a74757a0b15880f 100644
--- a/base/win/registry.h
+++ b/base/win/registry.h
@@ -66,16 +66,40 @@ class BASE_EXPORT RegKey {
// Deletes a single value within the key.
LONG DeleteValue(const wchar_t* name);
- LONG ReadValue(const wchar_t* name, void* data, DWORD* dsize,
+ // Getters:
+
+ // Returns an int32 value. If |name| is NULL or empty, returns the default
+ // value, if any.
+ LONG ReadValueDW(const wchar_t* name, DWORD* out_value) const;
+
+ // Returns an int64 value. If |name| is NULL or empty, returns the default
+ // value, if any.
+ LONG ReadInt64(const wchar_t* name, int64* out_value) const;
+
+ // Returns a string value. If |name| is NULL or empty, returns the default
+ // value, if any.
+ LONG ReadValue(const wchar_t* name, std::wstring* out_value) const;
+
+ // Returns raw data. If |name| is NULL or empty, returns the default
+ // value, if any.
+ LONG ReadValue(const wchar_t* name,
+ void* data,
+ DWORD* dsize,
DWORD* dtype) const;
- LONG ReadValue(const wchar_t* name, std::wstring* value) const;
- LONG ReadValueDW(const wchar_t* name, DWORD* value) const;
- LONG ReadInt64(const wchar_t* name, int64* value) const;
- LONG WriteValue(const wchar_t* name, const void* data, DWORD dsize,
+ // Setters:
+
+ // Sets an int32 value.
+ LONG WriteValue(const wchar_t* name, DWORD in_value);
+
+ // Sets a string value.
+ LONG WriteValue(const wchar_t* name, const wchar_t* in_value);
+
+ // Sets raw data, including type.
+ LONG WriteValue(const wchar_t* name,
+ const void* data,
+ DWORD dsize,
DWORD dtype);
- LONG WriteValue(const wchar_t* name, const wchar_t* value);
- LONG WriteValue(const wchar_t* name, DWORD value);
// Starts watching the key to see if any of its values have changed.
// The key must have been opened with the KEY_NOTIFY access privilege.
« no previous file with comments | « no previous file | base/win/registry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698