| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_REGISTRY_H_ | 5 #ifndef BASE_REGISTRY_H_ |
| 6 #define BASE_REGISTRY_H_ | 6 #define BASE_REGISTRY_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <windows.h> | 9 #include <windows.h> |
| 10 | 10 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 public: | 22 public: |
| 23 RegKey(); | 23 RegKey(); |
| 24 RegKey(HKEY rootkey, const wchar_t* subkey, REGSAM access); | 24 RegKey(HKEY rootkey, const wchar_t* subkey, REGSAM access); |
| 25 ~RegKey(); | 25 ~RegKey(); |
| 26 | 26 |
| 27 bool Create(HKEY rootkey, const wchar_t* subkey, REGSAM access); | 27 bool Create(HKEY rootkey, const wchar_t* subkey, REGSAM access); |
| 28 | 28 |
| 29 bool CreateWithDisposition(HKEY rootkey, const wchar_t* subkey, | 29 bool CreateWithDisposition(HKEY rootkey, const wchar_t* subkey, |
| 30 DWORD* disposition, REGSAM access); | 30 DWORD* disposition, REGSAM access); |
| 31 | 31 |
| 32 bool Open(HKEY rootkey, const wchar_t* subkey, REGSAM access); | 32 bool Open(HKEY rootkey, const wchar_t* subkey, REGSAM access = KEY_READ); |
| 33 | 33 |
| 34 // Creates a subkey or open it if it already exists. | 34 // Creates a subkey or open it if it already exists. |
| 35 bool CreateKey(const wchar_t* name, REGSAM access); | 35 bool CreateKey(const wchar_t* name, REGSAM access); |
| 36 | 36 |
| 37 // Opens a subkey | 37 // Opens a subkey |
| 38 bool OpenKey(const wchar_t* name, REGSAM access); | 38 bool OpenKey(const wchar_t* name, REGSAM access); |
| 39 | 39 |
| 40 void Close(); | 40 void Close(); |
| 41 | 41 |
| 42 DWORD ValueCount(); | 42 DWORD ValueCount(); |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 | 161 |
| 162 // Current index of the iteration. | 162 // Current index of the iteration. |
| 163 int index_; | 163 int index_; |
| 164 | 164 |
| 165 wchar_t name_[MAX_PATH]; | 165 wchar_t name_[MAX_PATH]; |
| 166 | 166 |
| 167 DISALLOW_COPY_AND_ASSIGN(RegistryKeyIterator); | 167 DISALLOW_COPY_AND_ASSIGN(RegistryKeyIterator); |
| 168 }; | 168 }; |
| 169 | 169 |
| 170 #endif // BASE_REGISTRY_H_ | 170 #endif // BASE_REGISTRY_H_ |
| OLD | NEW |