package gov.nist.hit.ds.docentryeditor.shared.model;

/**
 * <b>Enumeration of language codes regarding RFC 3066 standard</b> <a
 * href=http://www.i18nguy.com/unicode/language-identifiers.html> See RFC 3066
 * standard</a>
 */

public enum LanguageCode {
    CATALAN("ca"), FRENCH_ANDORRA("fr-AD"), ARABIC_UNITED_ARAB_EMIRATES("ar-AE"), PERSIAN_AFGHANISTAN(
            "fa-AF"), PUSHTO("ps"), UIGHUR("ug"), UZBEK_AFGHANISTAN("uz-AF"), ENGLISH_ANTIGUA_AND_BARBUDA(
            "en-AG"), ENGLISH_ANGUILLA("en-Al"), ALBANIAN("sq"), ARMENIAN("hy"), DUTCH_ANTILLES(
            "nl-AN"), KONGO("kg"), KUANYAMA("kj"), PORTUGUESE_ANGOLA("pt-AO"), WELSH_ARGENTINA(
            "cy-AR"), SPANISH_ARGENTINA("es-AR"), GUARANI("gn"), ENGLISH_AMERICAN_SAMOA(
            "en-AS"), SAMOAN("sm"), GERMAN_AUSTRIA("de-AT"), HUNGARIAN("hu"), ENGLISH_AUSTRALIA(
            "en-AU"), YIDDISH("yi"), DUTCH_ARUBA("nl-AW"), SWEDISH_ALAND_ISLANDS(
            "sv-AX"), AVARIC("av"), AZERBAIJANI("az"), AZERBAIJANI_ARABIC(
            "ar-Arab"), AZERBAIJANI_CYRL("az-Cyrl"), AZERBAIJANI_LATN("az-Latn"), OSSETIAN(
            "os"), BOSNIAN("bs"), CROATIAN_BOSIA_AND_HERZEGOVINA("hr-BA"), SERBIAN_BOSIA_AND_HERZEGOVINA(
            "sr-BA"), ENGLISH_BARBADOS("en-BB"), BENGALI_BENGLADAESH("bn-BD"), GERMAN_BELGIUM(
            "de-BE"), ENGLISH_BELGIUM("en-BE"), FRENCH_BELGIUM("fr-BE"), DUTCH_BELGIUM(
            "nl-BE"), WALLON("wa"), BAMBARA("bm"), FRENCH_BURKINA_FASO("fr-BF"), HAUSA(
            "ha"), BULGARIAN("bg"), CHURCH_SLAVIC("cu"), TURKISH_BULGARIA(
            "tr-BG"), ARABIC_BAHRAIN("ar-BH"), FRENCH_BURUNDI("fr-BI"), RUNDI(
            "rn"), FRENCH_BENIN("fr-BJ"), ENGLISH_BERMUDA("en-BM"), ENGLISH_DRUNEI_DARUSSALAM(
            "en-DN"), MALAY_DRUNEI_DARUSSALAM("ms-BN"), AYMARA("ay"), SPANISH_BOLIVIA(
            "es-BO"), PORTUGUESE_BRAZIL("pt-BR"), ENGLISH_BAHAMAS("en-BS"), DZONGKHA(
            "dz"), NEPALI("ne"), ENGLISH_BOTSWANA("en-BW"), SHONA("sn"), TSWANA_BOTSWANGA(
            "tn-BW"), BELARUSIAN("be"), ENGLISH_BELIZE("en-BZ"), CREE("cr"), ENGLISH_CANADA(
            "en-CA"), FRENCH_CANADA("fr-CA"), INUKTIKUT("iu"), OJIBWA("oj"), MALAY_COCOS_ISLANDS(
            "ms-CC"), FRENCH_DEMOCRATIC_REPUBLIC_CONGO("fr-CD"), LINGALA_DEMOCRATIC_REPUBLIC_CONGO(
            "ln-CD"), LUBA_KATANGA("lu"), FRENCH_CENTRAL_AFRICAN_REPUBLIC(
            "fr-CF"), SANGO("sg"), FRENCH_CONGO("fr-CG"), LINGALA_CONGO("ln-CG"), GERMAN_SWITZERLAN(
            "de-CH"), FRENCH_SWITZERLAND("fr-CH"), ITALIAN_SWITZERLAND("it-CH"), RAETO_ROMANCE(
            "rm"), AKAN("ak"), FRENCH_COTE_IVOIRE("fr-CI"), ENGLISH_COOK_ISLANDS(
            "en-CK"), SPANISH_CHILE("es-CL"), ENGLISH_CAMEROON("en-CM"), FRENCH_CAMEROON(
            "fr-CM"), TIBETAN("bo"), HAKKA("i-hak"), SICHUAN_YI("ii"), ZHUANG(
            "za"), CHINESE("zh-CN"), CHINESE_GAN("zh-gan"), CHINESE_GUOYU(
            "zh-guoyu"), CHINESE_HAKKA("zh-hakka"), CHINESE_HANS("zh-Hans"), CHINESE_HANT(
            "zh-Hant"), CHINESE_WUU("zh-wuu"), CHINESE_XIANG("zh-xiang"), CHINESE_YUE(
            "zh-yue"), SPANISH_COLOMBIA("es-CO"), SPANISH_COSTA_RICA("es-CR"), SERBIAN(
            "sr"), SERBIAN_CYRL("sr-Cyrl"), SERBIAN_LATN("sr-Latn"), SPANISH_CUBA(
            "es-CU"), PORTUGUESE_CAPE_VERDE("pt-CV"), GREEK_CYPRUS("el-CY"), TURKISH_CYPRUS(
            "tr-CY"), CZECH("cs"), DANISH_GERMANY("da-DE"), GERMAN("de-DE"), LOWER_SORBIAN(
            "dsb"), FRISIAN_GERMANY("fy-DE"), UPPER_SORBIAN("hsb"), LUXEMBOURGISH(
            "lb"), LOW_GERMAN("nds"), SORBIAN("wen"), AFAR_DJIBOUTI("aa-DJ"), FRENCH_DJIBOUTI(
            "fr-DJ"), SOMALI_DJIBOUTI("so-DJ"), DANISH("da-DK"), GERMAN_DENMARK(
            "de-DK"), ENGLISH_DOMINICA("en-DM"), SPANISH_DOMONICAN_REPUBLIC(
            "es-DO"), ARABIC_ALGERIA("ar-DZ"), SPANISH_ECUADOR("es-EC"), ESTONIAN(
            "et"), ARABIC_EGYPT("ar-EG"), AFAR_ERITREA("aa-ER"), BLIN("byn"), ENGLISH_ERITREA(
            "en-ER"), GEEZ_ERITREA("gez-ER"), TIGRINYA_ERITREA("ti-ER"), TIGRE(
            "tig"), ARAGONESE("an"), SPANISH("es-ES"), BASQUE("eu"), GALICIAN(
            "gl"), AFAR_ETHIPIA("aa-ET"), AMHARIC("am"), ENGLISH_ETHIOPIA(
            "en-ET"), GEEZ_ETHIPIA("gez-ET"), OROMO_ETHIOPIA("om-ET"), SIDAMO(
            "sid"), SOMALI_ETHIOPIA("so-ET"), TIGRINYA_ETHIOPIA("ti-ET"), WALAMO(
            "wal"), FINNISH("fi-FI"), INARI_SAMI("smn"), SWEDISH_FINLAND(
            "sv-FI"), ENGLISH_FIJI("en-FJ"), FIJAN("fj"), ENGLISH_FALKLAND_ISLANDS(
            "en-FK"), ENGLISH_MICRONESIA("en-FM"), DANISH_FAROE_ISLANDS("da-FO"), FAROESE(
            "fo"), BRETON("br"), CORSICAN("co"), GERMAN_FRANCE("de-FR"), FRENCH_FRANCE(
            "fr-FR"), OCCITAN("oc"), FRENCH_GABON("fr-GA"), WELSH_UNITED_KINGDOM(
            "cy-GB"), ENGLISH("en-GB"), FRENCH_UNITED_KINGDOM("fr-GB"), IRISH_UNITED_KINGDOM(
            "ga-GB"), GAELIC("gd"), MANX("gv"), CORNISH("kw"), ENGLISH_GRENADA(
            "en-GD"), ABKHAZIAN("ab"), GEORGIAN("ka"), FRENCH_GUIANA("fr-GF"), EWE(
            "ee"), ENGLISH_GHANA("en-GH"), TWI("tw"), ENGLISH_GIBRALTAR("en-GI"), DANISH_GREENLAND(
            "de-GL"), KALAALLISUT("kl"), ENGLISH_GAMBIA("en-GM"), WOLOF("wf"), FRENCH_GUINEA(
            "fr-GN"), FRENCH_GUADELOUPE("fr-GP"), SPANISH_EQUTORIAL_GUINEA(
            "es-GQ"), GREEK("el-GR"), SPANISH_GUATEMALA("es-GT"), CHAMORRO(
            "ch-GU"), ENGLISH_GUAM("en-GU"), PORTUGUESE_GUINEA_BISSAU("pt-GW"), ENGLISH_GUYANA(
            "en-GY"), ENGLISH_HONG_KONG("en-HK"), CHINESE_HANT_HONG_KONG(
            "zh-Hant-HK"), CHINESE_HONG_KONG("zh-HK"), SPANISH_HONDURAS("es-HN"), CROATIAN(
            "hr-HR"), ITALIAN_CROTIA("it-HR"), FRENCH_HAITI("fr-HT"), HAITIAN(
            "ht"), GERMAN_HUNGARY("de-HU"), HUNGARIAN_HUNGARY("hu-HU"), SLOVAK_HUNGARY(
            "sk-HU"), SERBIAN_HUNGARY("sr-HU"), INDONESIAN("id"), JAVANESE("jv"), SUNDANESE(
            "su"), ENGLISH_IRELAND("en-IE"), IRISH("ga-IE"), ARABIC_ISRAEL(
            "ar-IL"), ENGLISH_ISRAEL("en-IL"), HEBREW("he"), ARABIC_INDIA(
            "ar-IN"), ASSAMESE("as"), BIHARI("bh"), BENGALI_INDIA("bn-IN"), ENGLISH_INDIA(
            "en-IN"), GUJARATI("gu"), HINDI("hi"), KANNADA("kn"), KONKANI("kok"), KASHMIRI(
            "ks"), MALAYALAM("ml"), MARATHI("mr"), ORIYA("or"), PANJABI("pa"), PALI(
            "pi"), SANSKRIT("sa"), SINDHI_INDIA("sd-IN"), TAMIL_INDIA("ta-IN"), TELUGU(
            "te"), URDU_INDIA("ur-IN"), ENGLISH_INDIAN_OCEAN_TERRITORY("en-IO"), ARABIC_IRAQ(
            "ar-IQ"), KURDISH("ku"), AVESTAN("ae"), PERSIAN_IRAN("fa-IR"), ICELANDIC(
            "is"), GERMAN_ITALY("de-IT"), FRENCH_ITALY("fr-IT"), ITALIAN_ITALY(
            "it-IT"), SARDINIAN("sc"), ENGLIH_JAMAICA("en-JM"), ARABIC_JORDAN(
            "ar-JO"), JAPANESE("ja"), ENGLISH_KENYA("en-KE"), KIKUYU("ki"), OROMO_KENYA(
            "om-KE"), SOMALI_KENYA("so-KE"), SWAHILI_KENYA("sw-KE"), KIRGHIZ(
            "ky"), KHMER("km"), ENGLISH_KIRIBATI("en-KI"), FRENCH_COMOROS(
            "fr-KM"), ENGLISH_SAINT_KITTS_AND_NEVIS("en-KN"), KOREAN_SOUTH(
            "ko-KP"), KOREAN_NORTH("ko-KR"), ARABIC_KUWAIT("ar-KW"), ENGLISH_CAYMAN_ISLANDS(
            "en-KY"), KAZAKH("kk"), LAO("lo"), ARABIC_LEBANON("ar-LB"), FRENCH_LEBANON(
            "fr-LB"), ENGLISH_SAINT_LUCIA("en-LC"), GERMAN_LIECHTENSTEIN(
            "de-LI"), SINHALA("si"), ENGLISH_LIBERIA("en-LR"), ENGLISH_LESOTO(
            "en-LS"), SOUTHER_SOTP("st"), XHOSA("xh"), LITHUANIAN("lt"), GERMAN_LUXEMBOURG(
            "de-LU"), FRENCH_LUXEMBOURG("fr-LU"), LATVIAN("lv"), ARABIC_LIBYAN(
            "ar-LY"), ARABIC_MOROCCO("ar-MA"), FRENCH_MONACO("fr-MC"), MOLDAVIAN(
            "mo"), ROMANIAN("ro"), TURKISH("tr"), UKRAINIAN("uk"), FRENCH_MADAGASCAR(
            "fr-MG"), MALAGASY("mg"), ENGLISH_MARSHALL_ISLANDS("en-MH"), MARSHALLESE(
            "mh"), MACEDONIAN("mk"), FRENCH_MALI("fr-ML"), BURMESE("my"), MONGOLIAN(
            "mn"), CHINESE_MACAO("zh-MO"), CHAMORRO_NORTHERN_MARIANA_ISLANDS(
            "ch-MP"), ENGLISH_NORTHERN_MARIANA_ISLANDS("en-MP"), FRENCH_MARTINIQUE(
            "fr-MQ"), ARABIC_MAURITANIA("ar-MR"), ENGLISH_MONTSERRAT("en-MS"), ENGLISH_MALTA(
            "en-MT"), MALTESE("mt"), ENGLISH_MAURITUS("en-MU"), DIVEHI("dv"), ENGLISH_MALAWI(
            "en-MW"), CHICHEWA("ny"), SPANISH_MEXICO("es-MX"), MALAY("ms-MY"), PORTUGUESE_MOZAMBIQUE(
            "pt-MZ"), ENGLISH_NAMIBIA("en-NA"), HERERO("hz"), NDONGA("ng"), FRENCH_NEW_CALEDONIA(
            "fr-NC"), FULAK_NIGER("ff-NE"), FRENCH_NIGER("ff-NG"), KANURI("kr"), YORUBA(
            "yo"), SPANISH_NICARAGUA("es-NI"), FRISIAN_NETHERLANDS("fy-NL"), LIMBURGAN(
            "li"), DUTCH("nl-NL"), BOKMAL("nb"), NYNORSK("nn"), NORWEGIAN("no"), ENGLISH_NAURU(
            "en-NR"), NAURU("na"), ENGLISH_NIUE("en-NU"), ENGLISH_NEW_ZEALAND(
            "en-NZ"), MAORI("mi"), ARABIC_OMAN("ar-OM"), SPANISH_PANAMA("es-PA"), SPANISH_PERU(
            "es-PE"), QUECHUA("qu"), FRENCH_POLYNESIA("fr-PF"), TAHITIAN("ty"), ENGLISH_PAPUA_NEW_GUINEA(
            "en-PG"), HORI_MOTU("ho"), ENGLISH_PHILIPPINES("en-PH"), TAGALOG(
            "tl"), NGLISH_PAKISTAN("en-PK"), SINDHI_PAKISTAN("sd-PK"), URDU_PAKISTAN(
            "ur-PK"), GERMAND_POLAND("de-PL"), POLISH("pl"), FRENCH_SAINT_PIERRE_AND_MIQUELON(
            "fr-PM"), ENGLISH_PITCAIRN("en-PN"), ENGLISH_PUERTO_RICO("en-PR"), SPANISH_PUERTO_RICO(
            "es-PR"), ARABIC_PALESTINIAN_TERRITORY("ar-PS"), PORTUGUESE("pt-PT"), ENGLISH_PALAU(
            "en-PW"), SPANISH_PARAGUAY("es-PY"), ARABIC_QATAR("ar-QA"), FRENCH_REUNION(
            "fr-RE"), BASHKIR("ba"), CHECHEN("ce"), CHUVASH("cv"), KOMI("kv"), RUSSIAN(
            "ru-RU"), TATAR("tt"), ENGLISH_RWANDA("en-RW"), FRENCH_RWANDA(
            "fr-RW"), KINYARWANDA("rw"), ARABIC_SAUDI_ARABIA("ar-SA"), ENGLISH_SOLOMON_ISLANDS(
            "en-SB"), ENGLISH_SEYCHELLES("en-SC"), FRENCH_SEYCHELELS("fr-SC"), ARABIC_SUDAN(
            "ar-SD"), DINKA("din"), FINNISH_SWEDEN("fi-SE"), NORTHERN_SAMI("se"), S_SAMI(
            "sma"), N_SAMI("sme"), SWEDISH("sv-SE"), BENGALI_SINGAPORE("bn-SG"), ENGLISH_SINGAPORE(
            "en-SG"), MALAY_SINGAPORE("ms-SG"), TAMIL_SINGAPORE("ta-SG"), CHINESE_HANS_SINGAPORE(
            "zh-Hans-SG"), CHINESE_SINGAPORE("zh-SG"), ENGLISH_SAINT_HELENA(
            "en-SH"), HUNGARIAN_SLOVENIA("hu-SI"), ITALIAN_SLOVENIA("it-SI"), SLOVAK(
            "sk"), ENGLISH_SIERRA_LEONE("en-SL"), ITALIAN_SAN_MARINO("it-SM"), FULAH_SENEGAL(
            "ff-SN"), ARABIC_SOMALIA("ar-SO"), ENGLISH_SOMALIA("en-SO"), SOMALI(
            "so-SO"), DUTCH_SURINAME("nl-SR"), PORUTGUESE_SAO_TOME_AND_PRINCIPE(
            "pt-ST"), SPANISH_SALVADOR("es-SV"), ARABIC_SYRIA("ar-SY"), SYRIAC(
            "syr"), ENGLISH_SWAZILAND("en-SZ"), SWATI_SWAZILAND("ss-SZ"), ENGLISH_TURKS_AND_CAICOS_ISLANDS(
            "en-TC"), ARABIC_CHAD("ar-TD"), FRENCH_CHAD("fr-TD"), FRENCH_TOGO(
            "fr-TG"), THAI("th"), TAJIK("tj"), ENGLISH_TOKELAU("en-TK"), TURKMEN(
            "tk"), ARABIC_TUNISIA("ar-TN"), ENGLISH_TONGA("en-TO"), TONGAN("to"), TURKISH_TURKEY(
            "tr-TR"), ENGLISH_TRINIDAD_AND_TOBAGO("en-TT"), GILBERTESE("gil"), TUVALU(
            "tvl"), CHINESE_TAIWAN("zh-TW"), SWAHILI_TANZANIA("sw-TZ"), RUSSIAN_UKRAINE(
            "ru-UA"), ENGLISH_UGANDA("en-UG"), GANDA("lg"), ENGLISH_UNITED_STATES_MINOR_OUTLYING_ISLANDS(
            "en-UM"), ENGLISH_UNITED_STATES("en-US"), SPANISH_UNITED_STATES(
            "es-US"), HAWAIIAN("haw"), INUPIAQ("ik"), NAVAJO("nv"), SPANISH_URUGUAY(
            "es-UY"), UZBEK_CYRL("uz-Cyrl"), UZBEK_LATN("uz-Latn"), UZBEK(
            "uz-UZ"), FRENCH("fr"), ITALIAN("it"), LATIN("la"), ENGLISH_SAINT_VINCENT_AND_THE_GRENADINES(
            "en-VC"), SPANISH_VENEZUELA("es-VE"), ENGLISH_VIRGIN_ISLANDS(
            "en-VI"), VIETNAMESE("vi"), BISLAMA("bi"), ENGLISH_VANUATU("en-VU"), FRENCH_VANUATU(
            "fr-VU"), FRENCH_WALLIS_AND_FUTUNA("fr-WF"), ENGLISH_SAMOA("en-WS"), ARABIC_YEMEN(
            "ar-YE"), FRENCH_MAYOTTE("fr-YT"), AFRIKAANS("af"), ENGLISH_SOUTH_AFRICA(
            "en-ZA"), S_NDEBELE("nr"), SWATI_SOUTH_AFRICA("ss-ZA"), TSWANA_SOUTH_AFRICA(
            "tn-ZA"), TSONGA("ts"), VENDA("ve"), ZULU("zu"), ENGLISH_ZIMBABWE(
            "en-ZW"), N_NDEBELE("nd");

	/**
	 * RFC 3066 code for this language.
	 */
	private final String rfcCode;

	private LanguageCode(String rfcCode) {
		this.rfcCode = rfcCode;
	}

	private LanguageCode() {
		rfcCode = this.name();
	}

    public static LanguageCode getValueOf(String languageCode) {
        for (LanguageCode l : LanguageCode.values()) {
            if (l.toString().toLowerCase().equals(languageCode.toLowerCase())) {
                return l;
            }
        }
        return null;
    }

    @Override
    public String toString() {
        return this.rfcCode;
    }
}
