|
Home2L - C/C++ API v1.4-2-g83f4c (2025-08-23)
Smart Tools for a Private Home
|
Raw dictionary (base class for other dictionary variants).
This class stores typeless value data and is the base class for the other dirctionary classes. It should not be used directly.
#include "base.H"

Public Member Functions | |
Read access ... | |
| void | Del (int idx) |
| Delete entry; complexity is O(n). | |
| void | Del (const char *key) |
| Delete entry by key; complexity is O(n). | |
Write access ... | |
| const char * | GetKey (int idx) const |
| Get key by index. | |
| int | Find (const char *key, int *retInsIdx=NULL) |
Make binary search and return index of entry found or -1 if the key does not exist. If retInsIdx != NULL, the index to insert a new item is return in *retInsIdx. | |
| void | PrefixSearch (const char *key, int *retIdx0, int *retIdx1) |
Determine all elements with keys starting with key. | |
Debugging ... | |
| virtual void | Dump (const char *name) |
Dump contents by means of INFO logs (for debugging) | |
Public Member Functions inherited from CListRaw | |
| int | Entries () const |
| Get number of entries. | |
| void | Clear () |
| Clear the list. | |
| void | Del (int idx) |
| Delete entry; complexity is O(n). | |
|
inline |
Delete entry; complexity is O(n).
Entries with indices < 'idx' remain unchanged, all other entries may be modified.
This is important to consider if, for example, multiple entries are to be deleted in a loop.
Such a loop is legal if it traverses the indices in reverse order.
| void CDictRaw::PrefixSearch | ( | const char * | key, |
| int * | retIdx0, | ||
| int * | retIdx1 | ||
| ) |
Determine all elements with keys starting with key.
| key | Key prefix |
| retIdx0 | Pointer to first return value, index of first matching entry. |
| retIdx1 | Pointer to second return value, index behind last matching entry. |