mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-07-08 09:57:10 +02:00
More code cleanup and fixes in the MaxmindDB module.
Implemented the SearchNode wrapper.
This commit is contained in:
@ -12,10 +12,7 @@ namespace SqMod {
|
||||
*/
|
||||
class Description
|
||||
{
|
||||
// --------------------------------------------------------------------------------------------
|
||||
friend class Metadata; // Only a valid meta-data instance can construct this type.
|
||||
|
||||
protected:
|
||||
public:
|
||||
|
||||
// --------------------------------------------------------------------------------------------
|
||||
typedef MMDB_description_s Type; // The managed type.
|
||||
@ -28,6 +25,8 @@ protected:
|
||||
typedef Type& Reference; // Reference to the managed type.
|
||||
typedef const Type& ConstRef; // Constant reference to the managed type.
|
||||
|
||||
protected:
|
||||
|
||||
/* --------------------------------------------------------------------------------------------
|
||||
* Validate the managed database handle and throw an error if invalid.
|
||||
*/
|
||||
@ -37,8 +36,6 @@ protected:
|
||||
void Validate() const;
|
||||
#endif // _DEBUG
|
||||
|
||||
private:
|
||||
|
||||
/* --------------------------------------------------------------------------------------------
|
||||
* Validate the managed database handle and description pointer and throw an error if invalid.
|
||||
*/
|
||||
@ -54,15 +51,6 @@ private:
|
||||
DbRef m_Handle; // The database associated with this meta-data description.
|
||||
Pointer m_Description; // The inspected meta-data description structure.
|
||||
|
||||
/* --------------------------------------------------------------------------------------------
|
||||
* Construct and with a specific meta-data description.
|
||||
*/
|
||||
Description(const DbRef & db, Pointer description)
|
||||
: m_Handle(db), m_Description(description)
|
||||
{
|
||||
/* ... */
|
||||
}
|
||||
|
||||
public:
|
||||
|
||||
/* --------------------------------------------------------------------------------------------
|
||||
@ -74,6 +62,15 @@ public:
|
||||
/* ... */
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------
|
||||
* Construct and with a specific meta-data description.
|
||||
*/
|
||||
Description(const DbRef & db, Pointer description)
|
||||
: m_Handle(db), m_Description(description)
|
||||
{
|
||||
/* ... */
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------
|
||||
* Copy constructor.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user