This repository has been archived by the owner on Sep 28, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
i18n.h
49 lines (39 loc) · 1.49 KB
/
i18n.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
Copyright 2007 Mark Calderbank
This file is part of VOMP.
VOMP is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
VOMP is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with VOMP; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifndef I18N_H
#define I18N_H
#include <string>
#include <map>
class I18n
{
public:
I18n(char* tconfigDir);
typedef std::map<std::string,std::string> lang_code_list;
typedef std::pair<std::string,std::string> lang_code;
typedef std::map<std::string,std::string> trans_table;
typedef std::pair<std::string,std::string> trans_entry;
void findLanguages(void);
trans_table getLanguageContent(const std::string code);
const lang_code_list& getLanguageList(void);
private:
char* configDir;
std::string LanguageCode;
lang_code_list CodeList;
typedef std::multimap<std::string,std::string> lang_file_list;
typedef std::pair<std::string,std::string> lang_file;
lang_file_list FileList;
};
#endif