public string GetCountryTranslatedName(Alpha3Code alpha3Code, string languageCode) { if (Enum.TryParse(languageCode, true, out LanguageCode code)) { return(this.GetCountryTranslatedName(alpha3Code, code)); } return(null); }
public ICountryInfo GetCountry(Alpha3Code alpha3Code) { if (this._alpha3Code2CountryInfo.TryGetValue(alpha3Code, out ICountryInfo countryInfo)) { return(countryInfo); } return(null); }
public Country(string name, Alpha2Code alpha2Code, Alpha3Code alpha3Code, short numericCode, Region region, string subRegion) { Name = name; Alpha2Code = alpha2Code; Alpha3Code = alpha3Code; NumericCode = numericCode; Region = region; SubRegion = subRegion; }
public string GetCountryTranslatedName(Alpha3Code alpha3Code, CultureInfo culture, LanguageCode defaultLanguageCode) { var name = this.GetCountryTranslatedName(alpha3Code, culture); if (string.IsNullOrWhiteSpace(name) == true) { name = this.GetCountryTranslatedName(alpha3Code, defaultLanguageCode); } return(name); }
public string GetCountryTranslatedName(Alpha3Code alpha3Code, CultureInfo culture) { return(this.GetCountryTranslatedName(alpha3Code, culture.TwoLetterISOLanguageName)); }
public string GetCountryTranslatedName(Alpha3Code alpha3Code, LanguageCode languageCode) { return(this.GetCountryTranslatedName(GetCountry(alpha3Code), languageCode)); }
public override int GetHashCode() { return(Code.GetHashCode() ^ NumericCode.GetHashCode() ^ Alpha3Code.GetHashCode() ^ Fips10Code.GetHashCode() ^ Type.GetHashCode() ^ IdStatus.GetHashCode() ^ CurrencyCode.GetHashCode() ^ ParentCode.GetHashCode() ^ ParentGroupCodes.GetHashCode() ^ LanguageCodes.GetHashCode() ^ LanguageAltCodes.GetHashCode()); }
public string GetCountryTranslatedName(Alpha3Code alpha3Code, LanguageCode languageCode) { var countryInfo = this._countryProvider.GetCountry(alpha3Code); return(this.GetCountryTranslatedName(countryInfo, languageCode)); }