1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 // RegistryValueImpl.h: Schnittstelle für die Klasse RegistryValueImpl.
4 //////////////////////////////////////////////////////////////////////
6 #ifndef _REGISTRYVALUEIMPL_HXX_
7 #define _REGISTRYVALUEIMPL_HXX_
12 class RegistryValueImpl
16 //#################################
17 // Creation/Destruction
18 //#################################
20 RegistryValueImpl(const std::wstring
& Name
, int Value
);
22 RegistryValueImpl(const std::wstring
& Name
, const std::wstring
& Value
);
24 RegistryValueImpl(const std::wstring
& Name
, const std::string
& Value
);
26 #if (_MSC_VER >= 1300)
27 RegistryValueImpl::RegistryValueImpl(const RegistryValueImpl
& s
);
30 virtual ~RegistryValueImpl();
33 //#################################
35 //#################################
38 /** Returns the name of the value
40 std::wstring
GetName() const;
42 /** Return the size of data held
44 size_t GetDataSize() const;
46 /** Get a pointer to the data buffer
47 in order to copy the data
49 const void* GetDataBuffer() const;
51 /** Returns the data as unicode string
53 @precond GetType = STRING
55 std::wstring
GetDataAsUniString() const;
57 /** Returns the data as ansi string
59 @precond GetType = STRING
61 std::string
GetDataAsAnsiString() const;
63 /** Returns the data as number
65 @precond GetType = NUMBER
67 int GetDataAsInt() const;
69 /** Returns the type of the data
73 //#################################
75 //#################################
80 void SetName(const std::wstring
& NewName
);
84 void SetValue(const std::wstring
& NewValue
);
88 void SetValue(const std::string
& NewValue
);
92 void SetValue(int NewValue
);
94 //#################################
96 //#################################
101 std::wstring m_StringData
;
106 typedef std::auto_ptr
<RegistryValueImpl
> RegistryValue
;
111 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */