summaryrefslogtreecommitdiffstats
path: root/installerbuilder/libinstaller/3rdparty/p7zip_9.04/unix/CPP/7zip/UI/FileManager/TextPairs.h
diff options
context:
space:
mode:
Diffstat (limited to 'installerbuilder/libinstaller/3rdparty/p7zip_9.04/unix/CPP/7zip/UI/FileManager/TextPairs.h')
-rw-r--r--installerbuilder/libinstaller/3rdparty/p7zip_9.04/unix/CPP/7zip/UI/FileManager/TextPairs.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/installerbuilder/libinstaller/3rdparty/p7zip_9.04/unix/CPP/7zip/UI/FileManager/TextPairs.h b/installerbuilder/libinstaller/3rdparty/p7zip_9.04/unix/CPP/7zip/UI/FileManager/TextPairs.h
new file mode 100644
index 000000000..2670e0307
--- /dev/null
+++ b/installerbuilder/libinstaller/3rdparty/p7zip_9.04/unix/CPP/7zip/UI/FileManager/TextPairs.h
@@ -0,0 +1,31 @@
+// TextPairs.h
+
+#ifndef __FM_TEXT_PAIRS_H
+#define __FM_TEXT_PAIRS_H
+
+#include "Common/MyString.h"
+
+struct CTextPair
+{
+ UString ID;
+ UString Value;
+};
+
+class CPairsStorage
+{
+ CObjectVector<CTextPair> Pairs;
+ int FindID(const UString &id, int &insertPos);
+ int FindID(const UString &id);
+ void Sort();
+public:
+ void Clear() { Pairs.Clear(); };
+ bool ReadFromString(const UString &text);
+ void SaveToString(UString &text);
+
+ bool GetValue(const UString &id, UString &value);
+ UString GetValue(const UString &id);
+ void AddPair(const CTextPair &pair);
+ void DeletePair(const UString &id);
+};
+
+#endif