14#include <zypp/base/Logger.h>
15#include <zypp/base/String.h>
16#include <zypp/base/Gettext.h>
17#include <zypp/base/Hash.h>
40 std::string
name( IdString index_r )
46 { ret =
_(link->second); }
49 ret =
_(
"Unknown language: ");
51 ret += index_r.c_str();
58 typedef std::unordered_map<std::string,const char *>
CodeMap;
59 typedef CodeMap::const_iterator Link;
61 typedef std::unordered_map<IdString,Link> IndexMap;
74 : newIndex( index_r, index_r.asString() ) );
78 Link newIndex( IdString index_r,
const std::string & code_r )
82 return (_indexMap[index_r] = link);
85 CodeMap::value_type nval( code_r,
nullptr );
87 if ( code_r.size() > 3 || code_r.size() < 2 )
88 WAR <<
"Malformed LanguageCode '" << code_r <<
"' (expect 2 or 3-letter)" << endl;
91 if ( lcode != code_r )
93 WAR <<
"Malformed LanguageCode '" << code_r <<
"' (not lower case)" << endl;
99 nval.second = link->second;
102 MIL <<
"Remember LanguageCode '" << code_r <<
"': '" << (nval.second?nval.second:
"Unknown language") <<
"'" << endl;
103 return (_indexMap[index_r] =
_codeMap.insert( nval ).first);
140 {
return CodeMaps::instance().name(
_str ); }
152 const char *iso639_2;
153 const char *iso639_1;
159 const LangInit langInit[] = {
161 {
"aar",
"aa",
N_(
"Afar" ) },
163 {
"abk",
"ab",
N_(
"Abkhazian" ) },
165 {
"ace", NULL,
N_(
"Achinese" ) },
167 {
"ach", NULL,
N_(
"Acoli" ) },
169 {
"ada", NULL,
N_(
"Adangme" ) },
171 {
"ady", NULL,
N_(
"Adyghe" ) },
173 {
"afa", NULL,
N_(
"Afro-Asiatic (Other)" ) },
175 {
"afh", NULL,
N_(
"Afrihili" ) },
177 {
"afr",
"af",
N_(
"Afrikaans" ) },
179 {
"ain", NULL,
N_(
"Ainu" ) },
181 {
"aka",
"ak",
N_(
"Akan" ) },
183 {
"akk", NULL,
N_(
"Akkadian" ) },
185 {
"alb",
"sq",
N_(
"Albanian" ) },
187 {
"sqi", NULL,
N_(
"Albanian" ) },
189 {
"ale", NULL,
N_(
"Aleut" ) },
191 {
"alg", NULL,
N_(
"Algonquian Languages" ) },
193 {
"alt", NULL,
N_(
"Southern Altai" ) },
195 {
"amh",
"am",
N_(
"Amharic" ) },
197 {
"ang", NULL,
N_(
"English, Old (ca.450-1100)" ) },
199 {
"apa", NULL,
N_(
"Apache Languages" ) },
201 {
"ara",
"ar",
N_(
"Arabic" ) },
203 {
"arc", NULL,
N_(
"Aramaic" ) },
205 {
"arg",
"an",
N_(
"Aragonese" ) },
207 {
"arm",
"hy",
N_(
"Armenian" ) },
209 {
"hye", NULL,
N_(
"Armenian" ) },
211 {
"arn", NULL,
N_(
"Araucanian" ) },
213 {
"arp", NULL,
N_(
"Arapaho" ) },
215 {
"art", NULL,
N_(
"Artificial (Other)" ) },
217 {
"arw", NULL,
N_(
"Arawak" ) },
219 {
"asm",
"as",
N_(
"Assamese" ) },
221 {
"ast", NULL,
N_(
"Asturian" ) },
223 {
"ath", NULL,
N_(
"Athapascan Languages" ) },
225 {
"aus", NULL,
N_(
"Australian Languages" ) },
227 {
"ava",
"av",
N_(
"Avaric" ) },
229 {
"ave",
"ae",
N_(
"Avestan" ) },
231 {
"awa", NULL,
N_(
"Awadhi" ) },
233 {
"aym",
"ay",
N_(
"Aymara" ) },
235 {
"aze",
"az",
N_(
"Azerbaijani" ) },
237 {
"bad", NULL,
N_(
"Banda" ) },
239 {
"bai", NULL,
N_(
"Bamileke Languages" ) },
241 {
"bak",
"ba",
N_(
"Bashkir" ) },
243 {
"bal", NULL,
N_(
"Baluchi" ) },
245 {
"bam",
"bm",
N_(
"Bambara" ) },
247 {
"ban", NULL,
N_(
"Balinese" ) },
249 {
"baq",
"eu",
N_(
"Basque" ) },
251 {
"eus", NULL,
N_(
"Basque" ) },
253 {
"bas", NULL,
N_(
"Basa" ) },
255 {
"bat", NULL,
N_(
"Baltic (Other)" ) },
257 {
"bej", NULL,
N_(
"Beja" ) },
259 {
"bel",
"be",
N_(
"Belarusian" ) },
261 {
"bem", NULL,
N_(
"Bemba" ) },
263 {
"ben",
"bn",
N_(
"Bengali" ) },
265 {
"ber", NULL,
N_(
"Berber (Other)" ) },
267 {
"bho", NULL,
N_(
"Bhojpuri" ) },
269 {
"bih",
"bh",
N_(
"Bihari" ) },
271 {
"bik", NULL,
N_(
"Bikol" ) },
273 {
"bin", NULL,
N_(
"Bini" ) },
275 {
"bis",
"bi",
N_(
"Bislama" ) },
277 {
"bla", NULL,
N_(
"Siksika" ) },
279 {
"bnt", NULL,
N_(
"Bantu (Other)" ) },
281 {
"bos",
"bs",
N_(
"Bosnian" ) },
283 {
"bra", NULL,
N_(
"Braj" ) },
285 {
"bre",
"br",
N_(
"Breton" ) },
287 {
"btk", NULL,
N_(
"Batak (Indonesia)" ) },
289 {
"bua", NULL,
N_(
"Buriat" ) },
291 {
"bug", NULL,
N_(
"Buginese" ) },
293 {
"bul",
"bg",
N_(
"Bulgarian" ) },
295 {
"bur",
"my",
N_(
"Burmese" ) },
297 {
"mya", NULL,
N_(
"Burmese" ) },
299 {
"byn", NULL,
N_(
"Blin" ) },
301 {
"cad", NULL,
N_(
"Caddo" ) },
303 {
"cai", NULL,
N_(
"Central American Indian (Other)" ) },
305 {
"car", NULL,
N_(
"Carib" ) },
307 {
"cat",
"ca",
N_(
"Catalan" ) },
309 {
"cau", NULL,
N_(
"Caucasian (Other)" ) },
311 {
"ceb", NULL,
N_(
"Cebuano" ) },
313 {
"cel", NULL,
N_(
"Celtic (Other)" ) },
315 {
"cha",
"ch",
N_(
"Chamorro" ) },
317 {
"chb", NULL,
N_(
"Chibcha" ) },
319 {
"che",
"ce",
N_(
"Chechen" ) },
321 {
"chg", NULL,
N_(
"Chagatai" ) },
323 {
"chi",
"zh",
N_(
"Chinese" ) },
325 {
"zho", NULL,
N_(
"Chinese" ) },
327 {
"chk", NULL,
N_(
"Chuukese" ) },
329 {
"chm", NULL,
N_(
"Mari" ) },
331 {
"chn", NULL,
N_(
"Chinook Jargon" ) },
333 {
"cho", NULL,
N_(
"Choctaw" ) },
335 {
"chp", NULL,
N_(
"Chipewyan" ) },
337 {
"chr", NULL,
N_(
"Cherokee" ) },
339 {
"chu",
"cu",
N_(
"Church Slavic" ) },
341 {
"chv",
"cv",
N_(
"Chuvash" ) },
343 {
"chy", NULL,
N_(
"Cheyenne" ) },
345 {
"cmc", NULL,
N_(
"Chamic Languages" ) },
347 {
"cop", NULL,
N_(
"Coptic" ) },
349 {
"cor",
"kw",
N_(
"Cornish" ) },
351 {
"cos",
"co",
N_(
"Corsican" ) },
353 {
"cpe", NULL,
N_(
"Creoles and Pidgins, English-Based (Other)" ) },
355 {
"cpf", NULL,
N_(
"Creoles and Pidgins, French-Based (Other)" ) },
357 {
"cpp", NULL,
N_(
"Creoles and Pidgins, Portuguese-Based (Other)" ) },
359 {
"cre",
"cr",
N_(
"Cree" ) },
361 {
"crh", NULL,
N_(
"Crimean Tatar" ) },
363 {
"crp", NULL,
N_(
"Creoles and Pidgins (Other)" ) },
365 {
"csb", NULL,
N_(
"Kashubian" ) },
367 {
"cus", NULL,
N_(
"Cushitic (Other)" ) },
369 {
"cze",
"cs",
N_(
"Czech" ) },
371 {
"ces", NULL,
N_(
"Czech" ) },
373 {
"dak", NULL,
N_(
"Dakota" ) },
375 {
"dan",
"da",
N_(
"Danish" ) },
377 {
"dar", NULL,
N_(
"Dargwa" ) },
379 {
"day", NULL,
N_(
"Dayak" ) },
381 {
"del", NULL,
N_(
"Delaware" ) },
383 {
"den", NULL,
N_(
"Slave (Athapascan)" ) },
385 {
"dgr", NULL,
N_(
"Dogrib" ) },
387 {
"din", NULL,
N_(
"Dinka" ) },
389 {
"div",
"dv",
N_(
"Divehi" ) },
391 {
"doi", NULL,
N_(
"Dogri" ) },
393 {
"dra", NULL,
N_(
"Dravidian (Other)" ) },
395 {
"dsb", NULL,
N_(
"Lower Sorbian" ) },
397 {
"dua", NULL,
N_(
"Duala" ) },
399 {
"dum", NULL,
N_(
"Dutch, Middle (ca.1050-1350)" ) },
401 {
"dut",
"nl",
N_(
"Dutch" ) },
403 {
"nld", NULL,
N_(
"Dutch" ) },
405 {
"dyu", NULL,
N_(
"Dyula" ) },
407 {
"dzo",
"dz",
N_(
"Dzongkha" ) },
409 {
"efi", NULL,
N_(
"Efik" ) },
411 {
"egy", NULL,
N_(
"Egyptian (Ancient)" ) },
413 {
"eka", NULL,
N_(
"Ekajuk" ) },
415 {
"elx", NULL,
N_(
"Elamite" ) },
417 {
"eng",
"en",
N_(
"English" ) },
419 {
"enm", NULL,
N_(
"English, Middle (1100-1500)" ) },
421 {
"epo",
"eo",
N_(
"Esperanto" ) },
423 {
"est",
"et",
N_(
"Estonian" ) },
425 {
"ewe",
"ee",
N_(
"Ewe" ) },
427 {
"ewo", NULL,
N_(
"Ewondo" ) },
429 {
"fan", NULL,
N_(
"Fang" ) },
431 {
"fao",
"fo",
N_(
"Faroese" ) },
433 {
"fat", NULL,
N_(
"Fanti" ) },
435 {
"fij",
"fj",
N_(
"Fijian" ) },
437 {
"fil", NULL,
N_(
"Filipino" ) },
439 {
"fin",
"fi",
N_(
"Finnish" ) },
441 {
"fiu", NULL,
N_(
"Finno-Ugrian (Other)" ) },
443 {
"fon", NULL,
N_(
"Fon" ) },
445 {
"fre",
"fr",
N_(
"French" ) },
447 {
"fra", NULL,
N_(
"French" ) },
449 {
"frm", NULL,
N_(
"French, Middle (ca.1400-1600)" ) },
451 {
"fro", NULL,
N_(
"French, Old (842-ca.1400)" ) },
453 {
"fry",
"fy",
N_(
"Frisian" ) },
455 {
"ful",
"ff",
N_(
"Fulah" ) },
457 {
"fur", NULL,
N_(
"Friulian" ) },
459 {
"gaa", NULL,
N_(
"Ga" ) },
461 {
"gay", NULL,
N_(
"Gayo" ) },
463 {
"gba", NULL,
N_(
"Gbaya" ) },
465 {
"gem", NULL,
N_(
"Germanic (Other)" ) },
467 {
"geo",
"ka",
N_(
"Georgian" ) },
469 {
"kat", NULL,
N_(
"Georgian" ) },
471 {
"ger",
"de",
N_(
"German" ) },
473 {
"deu", NULL,
N_(
"German" ) },
475 {
"gez", NULL,
N_(
"Geez" ) },
477 {
"gil", NULL,
N_(
"Gilbertese" ) },
479 {
"gla",
"gd",
N_(
"Gaelic" ) },
481 {
"gle",
"ga",
N_(
"Irish" ) },
483 {
"glg",
"gl",
N_(
"Galician" ) },
485 {
"glv",
"gv",
N_(
"Manx" ) },
487 {
"gmh", NULL,
N_(
"German, Middle High (ca.1050-1500)" ) },
489 {
"goh", NULL,
N_(
"German, Old High (ca.750-1050)" ) },
491 {
"gon", NULL,
N_(
"Gondi" ) },
493 {
"gor", NULL,
N_(
"Gorontalo" ) },
495 {
"got", NULL,
N_(
"Gothic" ) },
497 {
"grb", NULL,
N_(
"Grebo" ) },
499 {
"grc", NULL,
N_(
"Greek, Ancient (to 1453)" ) },
501 {
"gre",
"el",
N_(
"Greek, Modern (1453-)" ) },
503 {
"ell", NULL,
N_(
"Greek, Modern (1453-)" ) },
505 {
"grn",
"gn",
N_(
"Guarani" ) },
507 {
"guj",
"gu",
N_(
"Gujarati" ) },
509 {
"gwi", NULL,
N_(
"Gwich'in" ) },
511 {
"hai", NULL,
N_(
"Haida" ) },
513 {
"hat",
"ht",
N_(
"Haitian" ) },
515 {
"hau",
"ha",
N_(
"Hausa" ) },
517 {
"haw", NULL,
N_(
"Hawaiian" ) },
519 {
"heb",
"he",
N_(
"Hebrew" ) },
521 {
"her",
"hz",
N_(
"Herero" ) },
523 {
"hil", NULL,
N_(
"Hiligaynon" ) },
525 {
"him", NULL,
N_(
"Himachali" ) },
527 {
"hin",
"hi",
N_(
"Hindi" ) },
529 {
"hit", NULL,
N_(
"Hittite" ) },
531 {
"hmn", NULL,
N_(
"Hmong" ) },
533 {
"hmo",
"ho",
N_(
"Hiri Motu" ) },
535 {
"hsb", NULL,
N_(
"Upper Sorbian" ) },
537 {
"hun",
"hu",
N_(
"Hungarian" ) },
539 {
"hup", NULL,
N_(
"Hupa" ) },
541 {
"iba", NULL,
N_(
"Iban" ) },
543 {
"ibo",
"ig",
N_(
"Igbo" ) },
545 {
"ice",
"is",
N_(
"Icelandic" ) },
547 {
"isl", NULL,
N_(
"Icelandic" ) },
549 {
"ido",
"io",
N_(
"Ido" ) },
551 {
"iii",
"ii",
N_(
"Sichuan Yi" ) },
553 {
"ijo", NULL,
N_(
"Ijo" ) },
555 {
"iku",
"iu",
N_(
"Inuktitut" ) },
557 {
"ile",
"ie",
N_(
"Interlingue" ) },
559 {
"ilo", NULL,
N_(
"Iloko" ) },
561 {
"ina",
"ia",
N_(
"Interlingua (International Auxiliary Language Association)" ) },
563 {
"inc", NULL,
N_(
"Indic (Other)" ) },
565 {
"ind",
"id",
N_(
"Indonesian" ) },
567 {
"ine", NULL,
N_(
"Indo-European (Other)" ) },
569 {
"inh", NULL,
N_(
"Ingush" ) },
571 {
"ipk",
"ik",
N_(
"Inupiaq" ) },
573 {
"ira", NULL,
N_(
"Iranian (Other)" ) },
575 {
"iro", NULL,
N_(
"Iroquoian Languages" ) },
577 {
"ita",
"it",
N_(
"Italian" ) },
579 {
"jav",
"jv",
N_(
"Javanese" ) },
581 {
"jbo", NULL,
N_(
"Lojban" ) },
583 {
"jpn",
"ja",
N_(
"Japanese" ) },
585 {
"jpr", NULL,
N_(
"Judeo-Persian" ) },
587 {
"jrb", NULL,
N_(
"Judeo-Arabic" ) },
589 {
"kaa", NULL,
N_(
"Kara-Kalpak" ) },
591 {
"kab", NULL,
N_(
"Kabyle" ) },
593 {
"kac", NULL,
N_(
"Kachin" ) },
595 {
"kal",
"kl",
N_(
"Kalaallisut" ) },
597 {
"kam", NULL,
N_(
"Kamba" ) },
599 {
"kan",
"kn",
N_(
"Kannada" ) },
601 {
"kar", NULL,
N_(
"Karen" ) },
603 {
"kas",
"ks",
N_(
"Kashmiri" ) },
605 {
"kau",
"kr",
N_(
"Kanuri" ) },
607 {
"kaw", NULL,
N_(
"Kawi" ) },
609 {
"kaz",
"kk",
N_(
"Kazakh" ) },
611 {
"kbd", NULL,
N_(
"Kabardian" ) },
613 {
"kha", NULL,
N_(
"Khasi" ) },
615 {
"khi", NULL,
N_(
"Khoisan (Other)" ) },
617 {
"khm",
"km",
N_(
"Khmer" ) },
619 {
"kho", NULL,
N_(
"Khotanese" ) },
621 {
"kik",
"ki",
N_(
"Kikuyu" ) },
623 {
"kin",
"rw",
N_(
"Kinyarwanda" ) },
625 {
"kir",
"ky",
N_(
"Kirghiz" ) },
627 {
"kmb", NULL,
N_(
"Kimbundu" ) },
629 {
"kok", NULL,
N_(
"Konkani" ) },
631 {
"kom",
"kv",
N_(
"Komi" ) },
633 {
"kon",
"kg",
N_(
"Kongo" ) },
635 {
"kor",
"ko",
N_(
"Korean" ) },
637 {
"kos", NULL,
N_(
"Kosraean" ) },
639 {
"kpe", NULL,
N_(
"Kpelle" ) },
641 {
"krc", NULL,
N_(
"Karachay-Balkar" ) },
643 {
"kro", NULL,
N_(
"Kru" ) },
645 {
"kru", NULL,
N_(
"Kurukh" ) },
647 {
"kua",
"kj",
N_(
"Kuanyama" ) },
649 {
"kum", NULL,
N_(
"Kumyk" ) },
651 {
"kur",
"ku",
N_(
"Kurdish" ) },
653 {
"kut", NULL,
N_(
"Kutenai" ) },
655 {
"lad", NULL,
N_(
"Ladino" ) },
657 {
"lah", NULL,
N_(
"Lahnda" ) },
659 {
"lam", NULL,
N_(
"Lamba" ) },
661 {
"lao",
"lo",
N_(
"Lao" ) },
663 {
"lat",
"la",
N_(
"Latin" ) },
665 {
"lav",
"lv",
N_(
"Latvian" ) },
667 {
"lez", NULL,
N_(
"Lezghian" ) },
669 {
"lim",
"li",
N_(
"Limburgan" ) },
671 {
"lin",
"ln",
N_(
"Lingala" ) },
673 {
"lit",
"lt",
N_(
"Lithuanian" ) },
675 {
"lol", NULL,
N_(
"Mongo" ) },
677 {
"loz", NULL,
N_(
"Lozi" ) },
679 {
"ltz",
"lb",
N_(
"Luxembourgish" ) },
681 {
"lua", NULL,
N_(
"Luba-Lulua" ) },
683 {
"lub",
"lu",
N_(
"Luba-Katanga" ) },
685 {
"lug",
"lg",
N_(
"Ganda" ) },
687 {
"lui", NULL,
N_(
"Luiseno" ) },
689 {
"lun", NULL,
N_(
"Lunda" ) },
691 {
"luo", NULL,
N_(
"Luo (Kenya and Tanzania)" ) },
693 {
"lus", NULL,
N_(
"Lushai" ) },
695 {
"mac",
"mk",
N_(
"Macedonian" ) },
697 {
"mkd", NULL,
N_(
"Macedonian" ) },
699 {
"mad", NULL,
N_(
"Madurese" ) },
701 {
"mag", NULL,
N_(
"Magahi" ) },
703 {
"mah",
"mh",
N_(
"Marshallese" ) },
705 {
"mai", NULL,
N_(
"Maithili" ) },
707 {
"mak", NULL,
N_(
"Makasar" ) },
709 {
"mal",
"ml",
N_(
"Malayalam" ) },
711 {
"man", NULL,
N_(
"Mandingo" ) },
713 {
"mao",
"mi",
N_(
"Maori" ) },
715 {
"mri", NULL,
N_(
"Maori" ) },
717 {
"map", NULL,
N_(
"Austronesian (Other)" ) },
719 {
"mar",
"mr",
N_(
"Marathi" ) },
721 {
"mas", NULL,
N_(
"Masai" ) },
723 {
"may",
"ms",
N_(
"Malay" ) },
725 {
"msa", NULL,
N_(
"Malay" ) },
727 {
"mdf", NULL,
N_(
"Moksha" ) },
729 {
"mdr", NULL,
N_(
"Mandar" ) },
731 {
"men", NULL,
N_(
"Mende" ) },
733 {
"mga", NULL,
N_(
"Irish, Middle (900-1200)" ) },
735 {
"mic", NULL,
N_(
"Mi'kmaq" ) },
737 {
"min", NULL,
N_(
"Minangkabau" ) },
739 {
"mis", NULL,
N_(
"Miscellaneous Languages" ) },
741 {
"mkh", NULL,
N_(
"Mon-Khmer (Other)" ) },
743 {
"mlg",
"mg",
N_(
"Malagasy" ) },
745 {
"mlt",
"mt",
N_(
"Maltese" ) },
747 {
"mnc", NULL,
N_(
"Manchu" ) },
749 {
"mni", NULL,
N_(
"Manipuri" ) },
751 {
"mno", NULL,
N_(
"Manobo Languages" ) },
753 {
"moh", NULL,
N_(
"Mohawk" ) },
755 {
"mol",
"mo",
N_(
"Moldavian" ) },
757 {
"mon",
"mn",
N_(
"Mongolian" ) },
759 {
"mos", NULL,
N_(
"Mossi" ) },
761 {
"mul", NULL,
N_(
"Multiple Languages" ) },
763 {
"mun", NULL,
N_(
"Munda languages" ) },
765 {
"mus", NULL,
N_(
"Creek" ) },
767 {
"mwl", NULL,
N_(
"Mirandese" ) },
769 {
"mwr", NULL,
N_(
"Marwari" ) },
771 {
"myn", NULL,
N_(
"Mayan Languages" ) },
773 {
"myv", NULL,
N_(
"Erzya" ) },
775 {
"nah", NULL,
N_(
"Nahuatl" ) },
777 {
"nai", NULL,
N_(
"North American Indian" ) },
779 {
"nap", NULL,
N_(
"Neapolitan" ) },
781 {
"nau",
"na",
N_(
"Nauru" ) },
783 {
"nav",
"nv",
N_(
"Navajo" ) },
785 {
"nbl",
"nr",
N_(
"Ndebele, South" ) },
787 {
"nde",
"nd",
N_(
"Ndebele, North" ) },
789 {
"ndo",
"ng",
N_(
"Ndonga" ) },
791 {
"nds", NULL,
N_(
"Low German" ) },
793 {
"nep",
"ne",
N_(
"Nepali" ) },
795 {
"new", NULL,
N_(
"Nepal Bhasa" ) },
797 {
"nia", NULL,
N_(
"Nias" ) },
799 {
"nic", NULL,
N_(
"Niger-Kordofanian (Other)" ) },
801 {
"niu", NULL,
N_(
"Niuean" ) },
803 {
"nno",
"nn",
N_(
"Norwegian Nynorsk" ) },
805 {
"nob",
"nb",
N_(
"Norwegian Bokmal" ) },
807 {
"nog", NULL,
N_(
"Nogai" ) },
809 {
"non", NULL,
N_(
"Norse, Old" ) },
811 {
"nor",
"no",
N_(
"Norwegian" ) },
813 {
"nso", NULL,
N_(
"Northern Sotho" ) },
815 {
"nub", NULL,
N_(
"Nubian Languages" ) },
817 {
"nwc", NULL,
N_(
"Classical Newari" ) },
819 {
"nya",
"ny",
N_(
"Chichewa" ) },
821 {
"nym", NULL,
N_(
"Nyamwezi" ) },
823 {
"nyn", NULL,
N_(
"Nyankole" ) },
825 {
"nyo", NULL,
N_(
"Nyoro" ) },
827 {
"nzi", NULL,
N_(
"Nzima" ) },
829 {
"oci",
"oc",
N_(
"Occitan (post 1500)" ) },
831 {
"oji",
"oj",
N_(
"Ojibwa" ) },
833 {
"ori",
"or",
N_(
"Oriya" ) },
835 {
"orm",
"om",
N_(
"Oromo" ) },
837 {
"osa", NULL,
N_(
"Osage" ) },
839 {
"oss",
"os",
N_(
"Ossetian" ) },
841 {
"ota", NULL,
N_(
"Turkish, Ottoman (1500-1928)" ) },
843 {
"oto", NULL,
N_(
"Otomian Languages" ) },
845 {
"paa", NULL,
N_(
"Papuan (Other)" ) },
847 {
"pag", NULL,
N_(
"Pangasinan" ) },
849 {
"pal", NULL,
N_(
"Pahlavi" ) },
851 {
"pam", NULL,
N_(
"Pampanga" ) },
853 {
"pan",
"pa",
N_(
"Panjabi" ) },
855 {
"pap", NULL,
N_(
"Papiamento" ) },
857 {
"pau", NULL,
N_(
"Palauan" ) },
859 {
"peo", NULL,
N_(
"Persian, Old (ca.600-400 B.C.)" ) },
861 {
"per",
"fa",
N_(
"Persian" ) },
863 {
"fas", NULL,
N_(
"Persian" ) },
865 {
"phi", NULL,
N_(
"Philippine (Other)" ) },
867 {
"phn", NULL,
N_(
"Phoenician" ) },
869 {
"pli",
"pi",
N_(
"Pali" ) },
871 {
"pol",
"pl",
N_(
"Polish" ) },
873 {
"pon", NULL,
N_(
"Pohnpeian" ) },
875 {
"por",
"pt",
N_(
"Portuguese" ) },
877 {
"pra", NULL,
N_(
"Prakrit Languages" ) },
879 {
"pro", NULL,
N_(
"Provencal, Old (to 1500)" ) },
881 {
"pus",
"ps",
N_(
"Pushto" ) },
883 {
"que",
"qu",
N_(
"Quechua" ) },
885 {
"raj", NULL,
N_(
"Rajasthani" ) },
887 {
"rap", NULL,
N_(
"Rapanui" ) },
889 {
"rar", NULL,
N_(
"Rarotongan" ) },
891 {
"roa", NULL,
N_(
"Romance (Other)" ) },
893 {
"roh",
"rm",
N_(
"Raeto-Romance" ) },
895 {
"rom", NULL,
N_(
"Romany" ) },
897 {
"rum",
"ro",
N_(
"Romanian" ) },
899 {
"ron", NULL,
N_(
"Romanian" ) },
901 {
"run",
"rn",
N_(
"Rundi" ) },
903 {
"rus",
"ru",
N_(
"Russian" ) },
905 {
"sad", NULL,
N_(
"Sandawe" ) },
907 {
"sag",
"sg",
N_(
"Sango" ) },
909 {
"sah", NULL,
N_(
"Yakut" ) },
911 {
"sai", NULL,
N_(
"South American Indian (Other)" ) },
913 {
"sal", NULL,
N_(
"Salishan Languages" ) },
915 {
"sam", NULL,
N_(
"Samaritan Aramaic" ) },
917 {
"san",
"sa",
N_(
"Sanskrit" ) },
919 {
"sas", NULL,
N_(
"Sasak" ) },
921 {
"sat", NULL,
N_(
"Santali" ) },
923 {
"scc",
"sr",
N_(
"Serbian" ) },
925 {
"srp", NULL,
N_(
"Serbian" ) },
927 {
"scn", NULL,
N_(
"Sicilian" ) },
929 {
"sco", NULL,
N_(
"Scots" ) },
931 {
"scr",
"hr",
N_(
"Croatian" ) },
933 {
"hrv", NULL,
N_(
"Croatian" ) },
935 {
"sel", NULL,
N_(
"Selkup" ) },
937 {
"sem", NULL,
N_(
"Semitic (Other)" ) },
939 {
"sga", NULL,
N_(
"Irish, Old (to 900)" ) },
941 {
"sgn", NULL,
N_(
"Sign Languages" ) },
943 {
"shn", NULL,
N_(
"Shan" ) },
945 {
"sid", NULL,
N_(
"Sidamo" ) },
947 {
"sin",
"si",
N_(
"Sinhala" ) },
949 {
"sio", NULL,
N_(
"Siouan Languages" ) },
951 {
"sit", NULL,
N_(
"Sino-Tibetan (Other)" ) },
953 {
"sla", NULL,
N_(
"Slavic (Other)" ) },
955 {
"slo",
"sk",
N_(
"Slovak" ) },
957 {
"slk", NULL,
N_(
"Slovak" ) },
959 {
"slv",
"sl",
N_(
"Slovenian" ) },
961 {
"sma", NULL,
N_(
"Southern Sami" ) },
963 {
"sme",
"se",
N_(
"Northern Sami" ) },
965 {
"smi", NULL,
N_(
"Sami Languages (Other)" ) },
967 {
"smj", NULL,
N_(
"Lule Sami" ) },
969 {
"smn", NULL,
N_(
"Inari Sami" ) },
971 {
"smo",
"sm",
N_(
"Samoan" ) },
973 {
"sms", NULL,
N_(
"Skolt Sami" ) },
975 {
"sna",
"sn",
N_(
"Shona" ) },
977 {
"snd",
"sd",
N_(
"Sindhi" ) },
979 {
"snk", NULL,
N_(
"Soninke" ) },
981 {
"sog", NULL,
N_(
"Sogdian" ) },
983 {
"som",
"so",
N_(
"Somali" ) },
985 {
"son", NULL,
N_(
"Songhai" ) },
987 {
"sot",
"st",
N_(
"Sotho, Southern" ) },
989 {
"spa",
"es",
N_(
"Spanish" ) },
991 {
"srd",
"sc",
N_(
"Sardinian" ) },
993 {
"srr", NULL,
N_(
"Serer" ) },
995 {
"ssa", NULL,
N_(
"Nilo-Saharan (Other)" ) },
997 {
"ssw",
"ss",
N_(
"Swati" ) },
999 {
"suk", NULL,
N_(
"Sukuma" ) },
1001 {
"sun",
"su",
N_(
"Sundanese" ) },
1003 {
"sus", NULL,
N_(
"Susu" ) },
1005 {
"sux", NULL,
N_(
"Sumerian" ) },
1007 {
"swa",
"sw",
N_(
"Swahili" ) },
1009 {
"swe",
"sv",
N_(
"Swedish" ) },
1011 {
"syr", NULL,
N_(
"Syriac" ) },
1013 {
"tah",
"ty",
N_(
"Tahitian" ) },
1015 {
"tai", NULL,
N_(
"Tai (Other)" ) },
1017 {
"tam",
"ta",
N_(
"Tamil" ) },
1019 {
"tat",
"tt",
N_(
"Tatar" ) },
1021 {
"tel",
"te",
N_(
"Telugu" ) },
1023 {
"tem", NULL,
N_(
"Timne" ) },
1025 {
"ter", NULL,
N_(
"Tereno" ) },
1027 {
"tet", NULL,
N_(
"Tetum" ) },
1029 {
"tgk",
"tg",
N_(
"Tajik" ) },
1031 {
"tgl",
"tl",
N_(
"Tagalog" ) },
1033 {
"tha",
"th",
N_(
"Thai" ) },
1035 {
"tib",
"bo",
N_(
"Tibetan" ) },
1037 {
"bod", NULL,
N_(
"Tibetan" ) },
1039 {
"tig", NULL,
N_(
"Tigre" ) },
1041 {
"tir",
"ti",
N_(
"Tigrinya" ) },
1043 {
"tiv", NULL,
N_(
"Tiv" ) },
1045 {
"tkl", NULL,
N_(
"Tokelau" ) },
1047 {
"tlh", NULL,
N_(
"Klingon" ) },
1049 {
"tli", NULL,
N_(
"Tlingit" ) },
1051 {
"tmh", NULL,
N_(
"Tamashek" ) },
1053 {
"tog", NULL,
N_(
"Tonga (Nyasa)" ) },
1055 {
"ton",
"to",
N_(
"Tonga (Tonga Islands)" ) },
1057 {
"tpi", NULL,
N_(
"Tok Pisin" ) },
1059 {
"tsi", NULL,
N_(
"Tsimshian" ) },
1061 {
"tsn",
"tn",
N_(
"Tswana" ) },
1063 {
"tso",
"ts",
N_(
"Tsonga" ) },
1065 {
"tuk",
"tk",
N_(
"Turkmen" ) },
1067 {
"tum", NULL,
N_(
"Tumbuka" ) },
1069 {
"tup", NULL,
N_(
"Tupi Languages" ) },
1071 {
"tur",
"tr",
N_(
"Turkish" ) },
1073 {
"tut", NULL,
N_(
"Altaic (Other)" ) },
1075 {
"tvl", NULL,
N_(
"Tuvalu" ) },
1077 {
"twi",
"tw",
N_(
"Twi" ) },
1079 {
"tyv", NULL,
N_(
"Tuvinian" ) },
1081 {
"udm", NULL,
N_(
"Udmurt" ) },
1083 {
"uga", NULL,
N_(
"Ugaritic" ) },
1085 {
"uig",
"ug",
N_(
"Uighur" ) },
1087 {
"ukr",
"uk",
N_(
"Ukrainian" ) },
1089 {
"umb", NULL,
N_(
"Umbundu" ) },
1091 {
"und", NULL,
N_(
"Undetermined" ) },
1093 {
"urd",
"ur",
N_(
"Urdu" ) },
1095 {
"uzb",
"uz",
N_(
"Uzbek" ) },
1097 {
"vai", NULL,
N_(
"Vai" ) },
1099 {
"ven",
"ve",
N_(
"Venda" ) },
1101 {
"vie",
"vi",
N_(
"Vietnamese" ) },
1103 {
"vol",
"vo",
N_(
"Volapuk" ) },
1105 {
"vot", NULL,
N_(
"Votic" ) },
1107 {
"wak", NULL,
N_(
"Wakashan Languages" ) },
1109 {
"wal", NULL,
N_(
"Walamo" ) },
1111 {
"war", NULL,
N_(
"Waray" ) },
1113 {
"was", NULL,
N_(
"Washo" ) },
1115 {
"wel",
"cy",
N_(
"Welsh" ) },
1117 {
"cym", NULL,
N_(
"Welsh" ) },
1119 {
"wen", NULL,
N_(
"Sorbian Languages" ) },
1121 {
"wln",
"wa",
N_(
"Walloon" ) },
1123 {
"wol",
"wo",
N_(
"Wolof" ) },
1125 {
"xal", NULL,
N_(
"Kalmyk" ) },
1127 {
"xho",
"xh",
N_(
"Xhosa" ) },
1129 {
"yao", NULL,
N_(
"Yao" ) },
1131 {
"yap", NULL,
N_(
"Yapese" ) },
1133 {
"yid",
"yi",
N_(
"Yiddish" ) },
1135 {
"yor",
"yo",
N_(
"Yoruba" ) },
1137 {
"ypk", NULL,
N_(
"Yupik Languages" ) },
1139 {
"zap", NULL,
N_(
"Zapotec" ) },
1141 {
"zen", NULL,
N_(
"Zenaga" ) },
1143 {
"zha",
"za",
N_(
"Zhuang" ) },
1145 {
"znd", NULL,
N_(
"Zande" ) },
1147 {
"zul",
"zu",
N_(
"Zulu" ) },
1149 {
"zun", NULL,
N_(
"Zuni" ) },
1151 { NULL, NULL, NULL }
1154 for (
const LangInit * i = langInit; i->iso639_2 != NULL; ++i)
1156 const char * name( i->name );
1158 if (i->iso639_1 != NULL)
Access to the sat-pools string space.
std::string name() const
Return the translated language name; if unknown the language code.
static const LanguageCode noCode
Empty code.
LanguageCode()
Default Ctor: noCode.
std::string toLower(const std::string &s)
Return lowercase version of s.
Easy-to use interface to the ZYPP dependency resolver.
CodeMaps()
Ctor initializes the code maps.
const LC & getIndex(IdString index_r)
Return LC for index_r, creating it if necessary.
std::string name(IdString index_r)
std::unordered_map< IdString, LC > CodeMap
static CodeMaps & instance()
The singleton.