Documentation
¶
Index ¶
- func Cleanse()
- func LoadCurrencyLocales() map[string]string
- func LoadCurrencySymbols() map[string]CurrencySymbols
- func LoadLocaleOverrides() []common.Locale
- type Carrier
- type CarrierService
- type CldrCurrencies
- type CldrCurrenciesMain
- type CldrCurrenciesNumbers
- type CldrCurrency
- type CldrIdentity
- type CldrIncomingCurrency
- type Continent
- type Country
- type CountryContinent
- type CountryDefaultLanguage
- type CountryDuty
- type CountryTimezone
- type Currency
- type CurrencyLocale
- type CurrencySymbols
- type IncomingCurrency
- type IncomingLanguage
- type IncomingLanguageLocale
- type IncomingLanguages
- type IncomingNumbers
- type IncomingNumbersMain
- type IncomingNumbersNumbers
- type IncomingNumbersSymbols
- type Language
- type LocaleName
- type Number
- type PaymentMethod
- type Province
- type ProvinceTranslation
- type Separators
- type Timezone
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadCurrencyLocales ¶
func LoadCurrencySymbols ¶
func LoadCurrencySymbols() map[string]CurrencySymbols
func LoadLocaleOverrides ¶
For some reason, some countries are missing from the underlying CLDR "Numbers" data that we ingest. It's easier to add this manual override than figure out how to fix the source data.
Types ¶
type Carrier ¶
type Carrier struct { Id string `json:"id"` Name string `json:"name"` TrackingUrl string `json:"tracking_url"` }
func LoadCarriers ¶
func LoadCarriers() []Carrier
type CarrierService ¶
type CarrierService struct { Id string `json:"id"` Name string `json:"name"` CarrierId string `json:"carrier_id"` }
func LoadCarrierServices ¶
func LoadCarrierServices() []CarrierService
type CldrCurrencies ¶
type CldrCurrencies struct {
Main map[string]CldrCurrenciesMain `json:"main"`
}
type CldrCurrenciesMain ¶
type CldrCurrenciesMain struct { Identity CldrIdentity `json:"identity"` Numbers CldrCurrenciesNumbers `json:"numbers"` }
type CldrCurrenciesNumbers ¶
type CldrCurrenciesNumbers struct {
Currencies map[string]CldrIncomingCurrency `json:"currencies"`
}
type CldrCurrency ¶
type CldrCurrency struct { Iso_4217_3 string `json:"iso_4217_3"` Symbols CurrencySymbols `json:"symbols"` }
type CldrIdentity ¶
type CldrIncomingCurrency ¶
type Continent ¶
type Continent struct { Code2 string `json:"code2"` Code3 string `json:"code3"` Name string `json:"name"` }
func LoadContinents ¶
func LoadContinents() []Continent
type Country ¶
type Country struct { Name string `json:"name"` Continent string `json:"continent"` Iso_3166_2 string `json:"iso_3166_2"` Iso_3166_3 string `json:"iso_3166_3"` Currency string `json:"currency"` }
func LoadCountries ¶
func LoadCountries() []Country
type CountryContinent ¶
type CountryContinent struct { ContinentCode string `json:"continent"` CountryCode string `json:"country"` }
func LoadCountryContinents ¶
func LoadCountryContinents() []CountryContinent
type CountryDefaultLanguage ¶
type CountryDefaultLanguage struct { LanguageCode string `json:"language"` CountryCode string `json:"country"` }
func LoadCountryDefaultLanguages ¶
func LoadCountryDefaultLanguages() []CountryDefaultLanguage
type CountryDuty ¶
func LoadCountryDuties ¶
func LoadCountryDuties() []CountryDuty
type CountryTimezone ¶
type CountryTimezone struct { TimezoneCode string `json:"timezone"` CountryCode string `json:"country"` }
func LoadCountryTimezones ¶
func LoadCountryTimezones() []CountryTimezone
type Currency ¶
type Currency struct { Name string `json:"name"` Iso_4217_3 string `json:"iso_4217_3"` NumberDecimals int `json:"number_decimals"` }
func LoadCurrencies ¶
func LoadCurrencies() []Currency
type CurrencyLocale ¶
type CurrencySymbols ¶
type IncomingCurrency ¶
type IncomingLanguage ¶
type IncomingLanguage struct { Iso_639_2 string `json:"iso639_1"` Names []string `json:"name"` Countries []string `json:"countries"` Locales []IncomingLanguageLocale `json:"langCultureMs"` }
type IncomingLanguageLocale ¶
type IncomingLanguages ¶
type IncomingLanguages struct { LanguageFamilies []string `json:"languageFamilies"` Languages []IncomingLanguage `json:"languages"` }
type IncomingNumbers ¶
type IncomingNumbers struct {
Main map[string]IncomingNumbersMain `json:"main"`
}
type IncomingNumbersMain ¶
type IncomingNumbersMain struct { Identity CldrIdentity `json:"identity"` Numbers IncomingNumbersNumbers `json:"numbers"` }
type IncomingNumbersNumbers ¶
type IncomingNumbersNumbers struct {
Symbols IncomingNumbersSymbols `json:"symbols-numberSystem-latn"`
}
type IncomingNumbersSymbols ¶
type Language ¶
type Language struct { Name string `json:"name"` Iso_639_2 string `json:"iso_639_2"` Countries []string `json:"countries"` Locales []string `json:"locales"` }
func LoadLanguages ¶
func LoadLanguages() []Language
type LocaleName ¶
func LoadLocaleNames ¶
func LoadLocaleNames() []LocaleName
type Number ¶
type Number struct { Country string `json:"country"` Language string `json:"language"` Separators Separators `json:"separators"` }
func LoadNumbers ¶
func LoadNumbers() []Number
type PaymentMethod ¶
type PaymentMethod struct { Id string `json:"id"` Type string `json:"type"` Name string `json:"name"` SmallWidth int `json:"small_width"` SmallHeight int `json:"small_height"` MediumWidth int `json:"medium_width"` MediumHeight int `json:"medium_height"` LargeWidth int `json:"large_width"` LargeHeight int `json:"large_height"` Regions []string `json:"regions"` Capabilities []string `json:"capabilities"` }
func LoadPaymentMethods ¶
func LoadPaymentMethods() []PaymentMethod
type Province ¶
type Province struct { Iso_3166_2 string `json:"iso_3166_2"` Name string `json:"name"` CountryCode string `json:"country"` ProvinceType string `json:"province_type"` }
func LoadProvinces ¶
func LoadProvinces() []Province
type ProvinceTranslation ¶
type ProvinceTranslation struct { LocaleId string `json:"locale_id"` ProvinceId string `json:"province_id"` Translation string `json:"translation"` }
func LoadProvinceTranslations ¶
func LoadProvinceTranslations() []ProvinceTranslation
type Separators ¶
Click to show internal directories.
Click to hide internal directories.