📄 cregistrykey.h
字号:
/*____________________________________________________________________________
Copyright (C) 2002 PGP Corporation
All rights reserved.
$Id: CRegistryKey.h,v 1.4 2002/08/06 20:10:46 dallen Exp $
____________________________________________________________________________*/
#ifndef Included_CRegistryKey_h // [
#define Included_CRegistryKey_h
#include "pgpClassesConfig.h"
_PGP_BEGIN
// Types
class CString;
// Class CRegistryKey
class CRegistryKey
{
NOT_COPYABLE(CRegistryKey)
public:
CRegistryKey() : mIsOpened(FALSE), mHKey(NULL) { }
~CRegistryKey();
operator HKEY() {return mHKey;}
operator const HKEY() const {return mHKey;}
PGPBoolean IsOpened() const {return mIsOpened;}
void Open(HKEY root, const char *section, REGSAM security =
KEY_ALL_ACCESS);
void Create(HKEY root, const char *section, REGSAM security =
KEY_ALL_ACCESS);
void Close();
PGPUInt32 GetValue(const char *valueName, PGPByte *buf,
PGPUInt32 sizeBuf) const;
PGPBoolean EnumValues(PGPUInt32 index, CString& valueName,
PGPUInt32& valueType) const;
PGPBoolean EnumSubkeys(PGPUInt32 index, CString& subkeyName) const;
void SetValue(const char *valueName, const PGPByte *data,
PGPUInt32 sizeData, PGPUInt32 dataType) const;
void DeleteValue(const char *valueName) const;
void DeleteSubkey(const char *subkeyName,
PGPBoolean recursive = FALSE) const;
private:
PGPBoolean mIsOpened;
HKEY mHKey;
};
_PGP_END
#endif // Included_CRegistryKey_h
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -