The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 1 | #ifndef LOCALIZE_H |
| 2 | #define LOCALIZE_H |
| 3 | |
| 4 | #include "XLIFFFile.h" |
| 5 | |
| 6 | #include <map> |
| 7 | #include <string> |
| 8 | |
| 9 | using namespace std; |
| 10 | |
| 11 | struct Reject |
| 12 | { |
| 13 | string file; |
| 14 | string name; |
| 15 | string comment; |
| 16 | }; |
| 17 | |
| 18 | struct Settings |
| 19 | { |
| 20 | string id; |
| 21 | string oldVersion; |
| 22 | string currentVersion; |
| 23 | vector<string> apps; |
| 24 | vector<Reject> reject; |
| 25 | }; |
| 26 | |
| 27 | int read_settings(const string& filename, map<string,Settings>* result, const string& rootDir); |
| 28 | string translated_file_name(const string& file, const string& locale); |
| 29 | bool keep_this_trans_unit(const string& file, const TransUnit& unit, void* cookie); |
| 30 | int validate_config(const string& settingsFile, const map<string,Settings>& settings, |
| 31 | const string& configs); |
| 32 | int validate_configs(const string& settingsFile, const map<string,Settings>& settings, |
| 33 | const vector<string>& configs); |
| 34 | int select_files(vector<string> *resFiles, const string& config, |
| 35 | const map<string,Settings>& settings, const string& rootDir); |
| 36 | int select_files(vector<vector<string> > *allResFiles, const vector<string>& configs, |
| 37 | const map<string,Settings>& settings, const string& rootDir); |
| 38 | |
| 39 | |
| 40 | #endif // LOCALIZE_H |