csStringHash Class Reference
A string-to-ID hash table. More...
#include <strhash.h>
Public Methods | |
| csStringHash (uint32 size=211) | |
| Constructor. | |
| ~csStringHash () | |
| Destructor. | |
| const char * | Register (const char *s, csStringID id) |
| Register a string with an ID. | |
| csStringID | Request (const char *s) |
| Request the ID for the given string. | |
| const char * | Request (csStringID id) |
| Request the string for a given ID. | |
| void | Clear () |
| Delete all stored strings. | |
Detailed Description
A string-to-ID hash table.Useful when you need to work with strings but want the performance characteristics of simple numeric comparisons. Register a string with a unique numeric ID and then compare ID's rather than comparing strings. You can fetch a string's ID via Request().
- See also:
- csStringSet
Definition at line 75 of file strhash.h.
Constructor & Destructor Documentation
|
|
Constructor.
|
|
|
Destructor.
|
Member Function Documentation
|
|
Delete all stored strings.
|
|
||||||||||||
|
Register a string with an ID.
|
|
|
Request the string for a given ID.
|
|
|
Request the ID for the given string.
|
The documentation for this class was generated from the following file:
- csutil/strhash.h
Generated for Crystal Space by doxygen 1.2.18
