2009-11-10 16:48:42 +01:00
|
|
|
#ifndef _RAR_STRLIST_
|
|
|
|
#define _RAR_STRLIST_
|
|
|
|
|
|
|
|
class StringList
|
|
|
|
{
|
|
|
|
private:
|
2020-07-15 00:40:26 +02:00
|
|
|
Array<wchar> StringData;
|
2009-11-10 16:48:42 +01:00
|
|
|
size_t CurPos;
|
|
|
|
|
2020-07-15 00:40:26 +02:00
|
|
|
size_t StringsCount;
|
2009-11-10 16:48:42 +01:00
|
|
|
|
2020-07-15 00:40:26 +02:00
|
|
|
size_t SaveCurPos[16],SavePosNumber;
|
2009-11-10 16:48:42 +01:00
|
|
|
public:
|
|
|
|
StringList();
|
|
|
|
void Reset();
|
2020-07-15 00:40:26 +02:00
|
|
|
void AddStringA(const char *Str);
|
|
|
|
void AddString(const wchar *Str);
|
|
|
|
bool GetStringA(char *Str,size_t MaxLength);
|
|
|
|
bool GetString(wchar *Str,size_t MaxLength);
|
|
|
|
bool GetString(wchar *Str,size_t MaxLength,int StringNum);
|
|
|
|
wchar* GetString();
|
|
|
|
bool GetString(wchar **Str);
|
2009-11-10 16:48:42 +01:00
|
|
|
void Rewind();
|
2020-07-15 00:40:26 +02:00
|
|
|
size_t ItemsCount() {return StringsCount;};
|
|
|
|
size_t GetCharCount() {return StringData.Size();}
|
|
|
|
bool Search(const wchar *Str,bool CaseSensitive);
|
2009-11-10 16:48:42 +01:00
|
|
|
void SavePosition();
|
|
|
|
void RestorePosition();
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|