This class contains the data structure support for char pointer set.
Definition at line 50 of file kcharptrset.h.
#include <kcharptrset.h>
Public Types |
|
enum | { KFBX_ITEM_PER_BLOCK = 20 } |
Public Member Functions |
|
KCharPtrSet (int pItemPerBlock=KFBX_ITEM_PER_BLOCK) | |
Class constructor. |
|
~KCharPtrSet () | |
Class destructor. |
|
void | Add (const char *pReference, kReference pItem) |
Add a new item. |
|
bool | Remove (const char *pReference) |
Removes an item. |
|
kReference | Get (const char *pReference, int *PIndex=NULL) |
Get an item's reference. |
|
kReference & | operator[] (int pIndex) |
Get an item's reference from index. |
|
kReference | GetFromIndex (int pIndex, const char **pReference=NULL) |
Get an item's reference from index. |
|
void | RemoveFromIndex (int pIndex) |
Removes an item by index. |
|
int | GetCount () const |
Get the number of item in the array.
|
|
void | Sort () |
Sorts the array. |
|
void | Clear () |
Clears the array. |
|
void | SetCaseSensitive (bool pIsCaseSensitive) |
anonymous enum |
Definition at line 52 of file kcharptrset.h.
{ KFBX_ITEM_PER_BLOCK = 20 };
KCharPtrSet | ( | int | pItemPerBlock =
KFBX_ITEM_PER_BLOCK |
) |
Class constructor.
pItemPerBlock | Number of item per block. Default is 20. |
~KCharPtrSet | ( | ) |
Class destructor.
void Add | ( | const char * | pReference, |
kReference | pItem | ||
) |
Add a new item.
pReference | char pointer reference to the item. |
pItem | kReference to the item. |
bool Remove | ( | const char * | pReference | ) |
Removes an item.
pReference | char reference to the item. |
kReference Get | ( | const char * | pReference, |
int * | PIndex =
NULL |
||
) |
Get an item's reference.
pReference | char reference to the item. |
PIndex | index to the item. |
kReference& operator[] | ( | int | pIndex | ) |
Get an item's reference from index.
pIndex | index to the item. |
kReference GetFromIndex | ( | int | pIndex, |
const char ** | pReference =
NULL |
||
) |
Get an item's reference from index.
pIndex | index to the item. |
pReference | char reference to the item. |
void RemoveFromIndex | ( | int | pIndex | ) |
int GetCount | ( | ) | const [inline] |
Get the number of item in the array.
Definition at line 105 of file kcharptrset.h.
{ return mCharPtrSetCount; }
void Sort | ( | ) |
Sorts the array.
void Clear | ( | ) |
Clears the array.
void SetCaseSensitive | ( | bool | pIsCaseSensitive | ) | [inline] |
Definition at line 129 of file kcharptrset.h.
{mIsCaseSensitive=pIsCaseSensitive;}