csScfStringSet Class Reference
The string set is a collection of unique strings. More...
#include <csutil/scfstrset.h>
Inheritance diagram for csScfStringSet:

Public Member Functions | |
virtual void | Clear () |
Remove all stored strings. | |
virtual bool | Contains (csStringID id) const |
Check if the set contains a string with a particular ID. | |
virtual bool | Contains (char const *s) const |
Check if the set contains a particular string. | |
csScfStringSet (size_t size=23) | |
Constructor. | |
virtual bool | Delete (csStringID id) |
Remove a string with the specified ID. | |
virtual bool | Delete (char const *s) |
Remove specified string. | |
virtual void | Empty () |
Remove all stored strings. | |
virtual size_t | GetSize () const |
Get the number of elements in the hash. | |
virtual bool | IsEmpty () const |
Return true if the hash is empty. | |
virtual const char * | Request (csStringID id) const |
Request the string corresponding to the given ID. | |
virtual csStringID | Request (const char *s) |
Request the numeric ID for the given string. | |
virtual | ~csScfStringSet () |
Destructor. | |
Public Attributes | |
SCF_DECLARE_IBASE |
Detailed Description
The string set is a collection of unique strings.Each string has an ID number. The most important operation is to request a string, which means to return the ID for the string, adding it to the collection if not already present. This is useful when you need to work with strings but want the performance characteristics of simple numeric comparisons. Rather than performing string comparisons, you instead compare the numeric string ID's.
Definition at line 34 of file scfstrset.h.
Constructor & Destructor Documentation
|
Constructor.
Definition at line 43 of file scfstrset.h. References SCF_CONSTRUCT_IBASE. |
|
Destructor.
Definition at line 47 of file scfstrset.h. References SCF_DESTRUCT_IBASE. |
Member Function Documentation
|
Remove all stored strings.
Implements iStringSet. Definition at line 105 of file scfstrset.h. References iStringSet::Empty(). |
|
Check if the set contains a string with a particular ID.
Implements iStringSet. Definition at line 78 of file scfstrset.h. |
|
Check if the set contains a particular string.
Implements iStringSet. Definition at line 70 of file scfstrset.h. |
|
Remove a string with the specified ID.
Implements iStringSet. Definition at line 92 of file scfstrset.h. |
|
Remove specified string.
Implements iStringSet. Definition at line 85 of file scfstrset.h. |
|
Remove all stored strings. When new strings are registered again, new ID values will be used; the old ID's will not be re-used. Implements iStringSet. Definition at line 99 of file scfstrset.h. |
|
Get the number of elements in the hash.
Implements iStringSet. Definition at line 109 of file scfstrset.h. |
|
Return true if the hash is empty.
Implements iStringSet. Definition at line 117 of file scfstrset.h. |
|
Request the string corresponding to the given ID.
Implements iStringSet. Definition at line 64 of file scfstrset.h. |
|
Request the numeric ID for the given string.
Implements iStringSet. Definition at line 56 of file scfstrset.h. |
The documentation for this class was generated from the following file:
- csutil/scfstrset.h
Generated for Crystal Space by doxygen 1.4.4