Emergency 2017 Dokumentation  v3.0.1
qsf::StringHashManager Class Reference

String hash manager class. More...

#include <StringHashManager.h>

Static Public Member Functions

static void registerStringHash (const char *string, uint32 hash)
 Static method to register a string hash. More...
 
static void destroyInstance ()
 Destroy the singleton instance. More...
 

Protected Member Functions

 StringHashManager ()
 Constructor. More...
 
 ~StringHashManager ()
 Destructor. More...
 
void internalRegisterStringHash (const char *string, uint32 hash)
 Registration of a string hash. More...
 

Static Protected Attributes

static StringHashManagermInstance
 Singleton instance of the StringHashManager class. More...
 

Detailed Description

String hash manager class.

Remarks
This class manages a list of all existing string hashes. So it is able to recognize hash conflicts and dump all string hashes to a file. Also, you can use it for debugging, in Visual Studio simply add a watch to qsf::StringHashManager::mInstance to get a sorted list of all hashed values together with the strings they represent.
Todo:
  • TODO(fw): The dump to file functionality is still missing. Could be called automatically in the destructor.

Definition at line 42 of file StringHashManager.h.

Constructor & Destructor Documentation

qsf::StringHashManager::StringHashManager ( )
protected

Constructor.

qsf::StringHashManager::~StringHashManager ( )
protected

Destructor.

Note
  • Not virtual by intent

Member Function Documentation

static void qsf::StringHashManager::destroyInstance ( )
static

Destroy the singleton instance.

void qsf::StringHashManager::internalRegisterStringHash ( const char *  string,
uint32  hash 
)
protected

Registration of a string hash.

static void qsf::StringHashManager::registerStringHash ( const char *  string,
uint32  hash 
)
static

Static method to register a string hash.

Member Data Documentation

StringHashManager* qsf::StringHashManager::mInstance
staticprotected

Singleton instance of the StringHashManager class.

Definition at line 93 of file StringHashManager.h.


The documentation for this class was generated from the following file: