1 // Common/Lang.h 2 3 #ifndef __COMMON_LANG_H 4 #define __COMMON_LANG_H 5 6 #include "MyString.h" 7 8 class CLang 9 { 10 wchar_t *_text; 11 CRecordVector<UInt32> _ids; 12 CRecordVector<UInt32> _offsets; 13 14 bool OpenFromString(const AString &s); 15 public: CLang()16 CLang(): _text(0) {} ~CLang()17 ~CLang() { Clear(); } 18 bool Open(CFSTR fileName, const char *id); 19 void Clear() throw(); 20 const wchar_t *Get(UInt32 id) const throw(); 21 }; 22 23 #endif 24