Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 BASE_WIN_REGISTRY_H_ | 5 #ifndef BASE_WIN_REGISTRY_H_ |
| 6 #define BASE_WIN_REGISTRY_H_ | 6 #define BASE_WIN_REGISTRY_H_ |
| 7 | 7 |
| 8 #include <windows.h> | 8 #include <windows.h> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 150 HKEY key_; // The registry key being iterated. | 150 HKEY key_; // The registry key being iterated. |
| 151 HANDLE watch_event_; | 151 HANDLE watch_event_; |
| 152 REGSAM wow64access_; | 152 REGSAM wow64access_; |
| 153 | 153 |
| 154 DISALLOW_COPY_AND_ASSIGN(RegKey); | 154 DISALLOW_COPY_AND_ASSIGN(RegKey); |
| 155 }; | 155 }; |
| 156 | 156 |
| 157 // Iterates the entries found in a particular folder on the registry. | 157 // Iterates the entries found in a particular folder on the registry. |
| 158 class BASE_EXPORT RegistryValueIterator { | 158 class BASE_EXPORT RegistryValueIterator { |
| 159 public: | 159 public: |
| 160 RegistryValueIterator(HKEY root_key, const wchar_t* folder_key); | 160 RegistryValueIterator(HKEY root_key, |
| 161 const wchar_t* folder_key, | |
| 162 REGSAM wow64access); | |
| 161 | 163 |
|
cpu_(ooo_6.6-7.5)
2014/10/06 19:48:57
yeah definitely two different ctors make sense her
| |
| 162 ~RegistryValueIterator(); | 164 ~RegistryValueIterator(); |
| 163 | 165 |
| 164 DWORD ValueCount() const; | 166 DWORD ValueCount() const; |
| 165 | 167 |
| 166 // True while the iterator is valid. | 168 // True while the iterator is valid. |
| 167 bool Valid() const; | 169 bool Valid() const; |
| 168 | 170 |
| 169 // Advances to the next registry entry. | 171 // Advances to the next registry entry. |
| 170 void operator++(); | 172 void operator++(); |
| 171 | 173 |
| (...skipping 19 matching lines...) Expand all Loading... | |
| 191 std::wstring name_; | 193 std::wstring name_; |
| 192 std::vector<wchar_t> value_; | 194 std::vector<wchar_t> value_; |
| 193 DWORD value_size_; | 195 DWORD value_size_; |
| 194 DWORD type_; | 196 DWORD type_; |
| 195 | 197 |
| 196 DISALLOW_COPY_AND_ASSIGN(RegistryValueIterator); | 198 DISALLOW_COPY_AND_ASSIGN(RegistryValueIterator); |
| 197 }; | 199 }; |
| 198 | 200 |
| 199 class BASE_EXPORT RegistryKeyIterator { | 201 class BASE_EXPORT RegistryKeyIterator { |
| 200 public: | 202 public: |
| 201 RegistryKeyIterator(HKEY root_key, const wchar_t* folder_key); | 203 RegistryKeyIterator(HKEY root_key, |
| 204 const wchar_t* folder_key, | |
| 205 REGSAM wow64access); | |
| 202 | 206 |
| 203 ~RegistryKeyIterator(); | 207 ~RegistryKeyIterator(); |
| 204 | 208 |
| 205 DWORD SubkeyCount() const; | 209 DWORD SubkeyCount() const; |
| 206 | 210 |
| 207 // True while the iterator is valid. | 211 // True while the iterator is valid. |
| 208 bool Valid() const; | 212 bool Valid() const; |
| 209 | 213 |
| 210 // Advances to the next entry in the folder. | 214 // Advances to the next entry in the folder. |
| 211 void operator++(); | 215 void operator++(); |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 226 | 230 |
| 227 wchar_t name_[MAX_PATH]; | 231 wchar_t name_[MAX_PATH]; |
| 228 | 232 |
| 229 DISALLOW_COPY_AND_ASSIGN(RegistryKeyIterator); | 233 DISALLOW_COPY_AND_ASSIGN(RegistryKeyIterator); |
| 230 }; | 234 }; |
| 231 | 235 |
| 232 } // namespace win | 236 } // namespace win |
| 233 } // namespace base | 237 } // namespace base |
| 234 | 238 |
| 235 #endif // BASE_WIN_REGISTRY_H_ | 239 #endif // BASE_WIN_REGISTRY_H_ |
| OLD | NEW |